Lists a user is on
Public lists other accounts have added the user to, newest first.
/user/{userId}/lists/membershipsParameters
userIdpath · string · requiredNumeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.
usernamequery · string · optionalHandle, with or without @. When set, it is used instead of userId: the API looks up the ID first, which makes the call a little slower. Still one billed call.
countquery · integer · optional · default 20Number of lists to ask X for, 1 to 100. Other values fall back to 20. X treats it as a hint.
cursorquery · string · optionalBottom cursor from the previous page. Leave it out for the first page. See Pagination.
Paginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call. See Pagination.
Example request
curl 'https://api.twittrapi.com/user/11348282/lists/memberships?count=20' \
--header 'X-API-KEY: YOUR_API_KEY'import httpx
# No SDK method for this endpoint yet, so this is a plain HTTP call.
resp = httpx.get(
"https://api.twittrapi.com/user/11348282/lists/memberships",
headers={"X-API-KEY": "YOUR_API_KEY"},
params={
"count": "20",
},
timeout=60,
)
data = resp.json()import { TwittrAPI } from "twittrapi";
const client = new TwittrAPI({ apiKey: process.env.TWITTRAPI_API_KEY });
// No wrapper method for this endpoint yet; client.get() sends the same authenticated GET.
const data = await client.get({
path: "/user/11348282/lists/memberships",
query: {
count: "20",
},
});curl 'https://twitter-aio.p.rapidapi.com/user/11348282/lists/memberships?count=20' \
--header 'x-rapidapi-key: YOUR_RAPIDAPI_KEY' \
--header 'x-rapidapi-host: twitter-aio.p.rapidapi.com'Base URL https://api.twittrapi.com, key in the X-API-KEY header. Python and Node.js use the official SDKs.
Response
Raw JSON of X's ListMemberships query, in the same shape as /user/{userId}/lists. X may add an errors array next to complete data when it cannot decode one nested field of a list; the lists are still there.
Simple format (?format=simple or X-Response-Format: simple): Collection of List objects, as /user/{userId}/lists. Schema.
{
"data": {
"user": {
"result": {
"__typename": "User",
"timeline": {
"timeline": {
"instructions": [
{
"type": "TimelineClearCache"
},
{
"direction": "Top",
"type": "TimelineTerminateTimeline"
},
{
"entries": [
{
"content": {
"__typename": "TimelineTimelineItem",
"clientEventInfo": {
"component": "MembershipsSgs",
"element": "list"
},
"entryType": "TimelineTimelineItem",
"itemContent": {
"__typename": "TimelineTwitterList",
"itemType": "TimelineTwitterList",
"list": {
"created_at": 1796025212000,
"default_banner_media": {
"media_info": {
"original_img_height": 375,
"original_img_url": "https://pbs.twimg.com/media/GkIQZXyWsAAs-uP.png",
"original_img_width": 1125,
"salient_rect": {
"height": 1,
"left": 562,
"top": 187,
"width": 1
}
}
},
"default_banner_media_results": {},
"description": "",
"facepile_urls": [],
"following": false,
"id": "TGlzdDoxOTAwMDAwMDAwMDAwMDAwMDAx",
"id_str": "1900000000000000001",
"is_member": false,
"member_count": 25,
"members_context": "25 members",
"mode": "Public",
"muting": false,
"name": "HABERLER",
"pinning": false,
"subscriber_count": 0,
"user_results": {
"result": {
"__typename": "User",
"action_counts": {
"favorites_count": 62
},
"affiliates_highlighted_label": {},
"avatar": {
"image_url": "https://pbs.twimg.com/profile_images/example/avatar_normal.jpg"
},
"core": {
"created_at": "Sun Mar 31 16:00:39 +0000 2024",
"name": "Example User 1",
"screen_name": "example_user_1"
},
"follow_request_sent": false,
"has_graduated_access": true,
"id": "VXNlcjoxMDAwMDAwMDAwMDAwMDAwMDAx",
"is_blue_verified": false,
"location": {
"location": ""
},
"media_permissions": {
"can_media_tag": true
},
"notifications_settings": {
"notifications_enabled": false
},
"parody_commentary_fan_label": "None",
"pinned_items": {},
"possibly_sensitive": false,
"privacy": {
"protected": false
},
"profile_bio": {
"description": "Example bio.",
"entities": {
"description": {
"urls": []
}
}
},
"profile_image_shape": "Circle",
"profile_metadata": {
"profile_interstitial_type": ""
},
"profile_translation": {
"translator_type": "none"
},
"relationship_counts": {
"followers": 0,
"following": 0
},
"relationship_perspectives": {
"blocked_by": false,
"blocking": false,
"followed_by": false,
"following": false,
"live_following": false,
"muting": false
},
"rest_id": "1000000000000000001",
"super_follow_eligible": false,
"super_followed_by": false,
"super_following": false,
"tweet_counts": {
"media_tweets": 0,
"tweets": 1
},
"verification": {
"verified": false
},
"website": {
"url": ""
},
"legacy": {
"blocked_by": false,
"blocking": false,
"can_media_tag": true,
"created_at": "Sun Mar 31 16:00:39 +0000 2024",
"default_profile_image": true,
"description": "Example bio.",
"entities": {
"description": {
"urls": []
}
},
"fast_followers_count": 0,
"favourites_count": 62,
"follow_request_sent": false,
"followed_by": false,
"followers_count": 0,
"following": false,
"friends_count": 0,
"is_translator": false,
"location": "",
"media_count": 0,
"muting": false,
"name": "Example User 1",
"needs_phone_verification": false,
"normal_followers_count": 0,
"notifications": false,
"possibly_sensitive": false,
"profile_image_url_https": "https://pbs.twimg.com/profile_images/example/avatar_normal.jpg",
"profile_interstitial_type": "",
"protected": false,
"screen_name": "example_user_1",
"statuses_count": 1,
"time_zone": "",
"translator_type": "none",
"utc_offset": 0,
"verified": false,
"want_retweets": false,
"withheld_description": "",
"withheld_scope": ""
}
}
}
}
}
},
"entryId": "list-2127310045327057210",
"sortIndex": "2127344550585303040"
},
{
"content": {
"__typename": "TimelineTimelineItem",
"clientEventInfo": {
"component": "MembershipsSgs",
"element": "list"
},
"entryType": "TimelineTimelineItem",
"itemContent": {
"__typename": "TimelineTwitterList",
"itemType": "TimelineTwitterList",
"list": {
"created_at": 1795990341000,
"default_banner_media": {
"media_info": {
"original_img_height": 375,
"original_img_url": "https://pbs.twimg.com/media/GkIPtGVXMAAz8Rh.png",
"original_img_width": 1125,
"salient_rect": {
"height": 1,
"left": 562,
"top": 187,
"width": 1
}
}
},
"default_banner_media_results": {},
"description": "",
"facepile_urls": [],
"following": false,
"id": "TGlzdDoxOTAwMDAwMDAwMDAwMDAwMDAy",
"id_str": "1900000000000000002",
"is_member": false,
"member_count": 40,
"members_context": "40 members",
"mode": "Public",
"muting": false,
"name": "News",
"pinning": false,
"subscriber_count": 0,
"user_results": {
"result": {
"__typename": "User",
"action_counts": {
"favorites_count": 131
},
"affiliates_highlighted_label": {},
"avatar": {
"image_url": "https://pbs.twimg.com/profile_images/example/avatar_normal.jpg"
},
"core": {
"created_at": "Sun Nov 15 14:20:53 +0000 2015",
"name": "Example User 2",
"screen_name": "example_user_2"
},
"follow_request_sent": false,
"has_graduated_access": true,
"id": "VXNlcjoxMDAwMDAwMDAwMDAwMDAwMDAy",
"is_blue_verified": false,
"location": {
"location": ""
},
"media_permissions": {
"can_media_tag": true
},
"notifications_settings": {
"notifications_enabled": false
},
"parody_commentary_fan_label": "None",
"pinned_items": {
"tweet_ids_str": [
"966839684621103106"
]
},
"possibly_sensitive": false,
"privacy": {
"protected": false
},
"profile_bio": {
"description": "Example bio.",
"entities": {
"description": {
"urls": []
}
}
},
"profile_image_shape": "Circle",
"profile_metadata": {
"profile_interstitial_type": ""
},
"profile_translation": {
"translator_type": "none"
},
"relationship_counts": {
"followers": 107,
"following": 80
},
"relationship_perspectives": {
"blocked_by": false,
"blocking": false,
"followed_by": false,
"following": false,
"live_following": false,
"muting": false
},
"rest_id": "1000000000000000002",
"super_follow_eligible": false,
"super_followed_by": false,
"super_following": false,
"tweet_counts": {
"media_tweets": 0,
"tweets": 10
},
"verification": {
"verified": false
},
"website": {
"url": ""
},
"legacy": {
"blocked_by": false,
"blocking": false,
"can_media_tag": true,
"created_at": "Sun Nov 15 14:20:53 +0000 2015",
"default_profile_image": false,
"description": "Example bio.",
"entities": {
"description": {
"urls": []
}
},
"fast_followers_count": 0,
"favourites_count": 131,
"follow_request_sent": false,
"followed_by": false,
"followers_count": 107,
"following": false,
"friends_count": 80,
"is_translator": false,
"location": "",
"media_count": 0,
"muting": false,
"name": "Example User 2",
"needs_phone_verification": false,
"normal_followers_count": 107,
"notifications": false,
"pinned_tweet_ids_str": [
"966839684621103106"
],
"possibly_sensitive": false,
"profile_image_url_https": "https://pbs.twimg.com/profile_images/example/avatar_normal.jpg",
"profile_interstitial_type": "",
"protected": false,
"screen_name": "example_user_2",
"statuses_count": 10,
"time_zone": "",
"translator_type": "none",
"utc_offset": 0,
"verified": false,
"want_retweets": false,
"withheld_description": "",
"withheld_scope": ""
}
}
}
}
}
},
"entryId": "list-2127163783395086489",
"sortIndex": "2127344550585303039"
},
{
"content": {
"__typename": "TimelineTimelineCursor",
"cursorType": "Bottom",
"entryType": "TimelineTimelineCursor",
"value": "6738721989367153024|2127344550585303033"
},
"entryId": "cursor-bottom-2127344550585303035",
"sortIndex": "2127344550585303035"
},
{
"content": {
"__typename": "TimelineTimelineCursor",
"cursorType": "Top",
"entryType": "TimelineTimelineCursor",
"value": "-1|2127344550585303041"
},
"entryId": "cursor-top-2127344550585303041",
"sortIndex": "2127344550585303041"
}
],
"type": "TimelineAddEntries"
}
]
}
}
}
}
}
}{
"data": [
{
"id": "1900000000000000001",
"name": "HABERLER",
"description": "",
"createdAt": "2026-11-30T07:53:32Z",
"memberCount": 25,
"followerCount": 0,
"private": false,
"bannerUrl": "https://pbs.twimg.com/media/GkIQZXyWsAAs-uP.png",
"owner": {
"id": "1000000000000000001",
"username": "example_user_1"
}
},
{
"id": "1900000000000000002",
"name": "News",
"description": "",
"createdAt": "2026-11-29T22:12:21Z",
"memberCount": 40,
"followerCount": 0,
"private": false,
"bannerUrl": "https://pbs.twimg.com/media/GkIPtGVXMAAz8Rh.png",
"owner": {
"id": "1000000000000000002",
"username": "example_user_2"
}
}
],
"nextCursor": "6738721989367153024|2127344550585303033",
"previousCursor": null,
"hasNextPage": true
}In the raw format, field names and nesting come from X and can change without notice. See Response format; the simple format keeps a fixed schema.
Errors
- 422userId is not numeric, or the username lookup failed.
- 400userId is -1 and username is missing, or the username contains characters X blocks.
- 404The user could not be found.
Errors every endpoint can return (401, 402, 403, 404, 408, 409, 429, 5xx), and which of them are charged, are on the Errors page. Calls that fail with 400, 407, 408, 409 or a 5xx error are refunded.