Passer au contenu principal
POST
/
2
/
users
/
{id}
/
followed_lists
Suivre une liste
curl --request POST \
  --url https://api.x.com/2/users/{id}/followed_lists \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "list_id": "1146654567674912769"
}
'
{
  "data": {
    "following": true
  },
  "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.

Paramètres de chemin

id
string
requis

L’ID de l’utilisateur source authentifié qui suivra la Liste. Identifiant unique de cet utilisateur. La valeur doit correspondre à celle de l’utilisateur authentifié.

Exemple:

"2244994945"

Corps

application/json
list_id
string
requis

L’identifiant unique de cette Liste.

Pattern: ^[0-9]{1,19}$
Exemple:

"1146654567674912769"

Réponse

La requête a réussi.

data
object
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).