Passer au contenu principal
POST
/
2
/
lists
Créer une liste
curl --request POST \
  --url https://api.x.com/2/lists \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "private": false
}
'
{
  "errors": [
    {
      "title": "<string>",
      "type": "<string>",
      "detail": "<string>",
      "status": 123
    }
  ]
}

Autorisations

Authorization
string
header
requis

The access token received from the authorization server in the OAuth 2.0 flow.

Corps

application/json
name
string
requis
Required string length: 1 - 25
description
string
Maximum string length: 100
private
boolean
défaut:false

Réponse

La requête a réussi.

data
object

Une Liste X est un groupe de comptes sélectionnés.

errors
object[]
Minimum array length: 1

Un objet HTTP Problem Details, tel que défini dans la RFC IETF 7807 (https://tools.ietf.org/html/rfc7807).