Documentation Index
Fetch the complete documentation index at: https://docs.x.com/llms.txt
Use this file to discover all available pages before exploring further.
This guide walks you through retrieving members of a List.
PrerequisitesBefore you begin, you’ll need:
Get List members
Find the List ID
You can find the List ID in the URL when viewing a List:https://x.com/i/lists/84839422
└── This is the List ID
Request the List members
curl "https://api.x.com/2/lists/84839422/members?\
user.fields=created_at,username,verified&\
max_results=100" \
-H "Authorization: Bearer $BEARER_TOKEN"
Review the response
{
"data": [
{
"id": "1319036828964454402",
"name": "Birdwatch",
"username": "birdwatch",
"created_at": "2020-10-21T22:04:47.000Z",
"verified": true
},
{
"id": "1065249714214457345",
"name": "Spaces",
"username": "TwitterSpaces",
"created_at": "2018-11-21T14:24:58.000Z",
"verified": true
}
],
"meta": {
"result_count": 2,
"next_token": "5349804505549807616"
}
}
Include additional data
Use expansions to get related data like pinned Posts:
curl "https://api.x.com/2/lists/84839422/members?\
user.fields=created_at&\
expansions=pinned_tweet_id&\
tweet.fields=created_at" \
-H "Authorization: Bearer $BEARER_TOKEN"
Next steps
Manage List members
Add and remove members
List lookup
Get List details
API Reference
Full endpoint documentation