List details
Name, description, owner and member and subscriber counts of a list.
/lists/detailsParameters
listIdquery · string · requiredNumeric list ID, the number in the list URL (x.com/i/lists/<listId>).
Example request
curl 'https://api.twittrapi.com/lists/details?listId=84839422' \
--header 'X-API-KEY: YOUR_API_KEY'from twittrapi import TwittrAPI
client = TwittrAPI(api_key="YOUR_API_KEY")
data = client.lists.details("84839422")import { TwittrAPI } from "twittrapi";
const client = new TwittrAPI({ apiKey: process.env.TWITTRAPI_API_KEY });
const data = await client.lists.details("84839422");curl 'https://twitter-aio.p.rapidapi.com/lists/details?listId=84839422' \
--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 ListByRestId query (data.list). X may add an errors array next to complete data when it cannot decode one nested field, e.g. the default banner; the rest of the list is still there.
Simple format (?format=simple or X-Response-Format: simple): {data: List}. Schema.
{
"data": {
"list": {
"created_at": 1360088061000,
"default_banner_media": {
"media_info": {
"original_img_height": 375,
"original_img_url": "https://pbs.twimg.com/media/GkIQyCGWYAA4UdW.png",
"original_img_width": 1125,
"salient_rect": {
"height": 1,
"left": 562,
"top": 187,
"width": 1
}
}
},
"default_banner_media_results": {},
"description": "Accounts managed by Twitter, Inc.",
"facepile_urls": [
"https://pbs.twimg.com/profile_images/1000000000000000000/example_normal.jpg",
"https://pbs.twimg.com/profile_images/1000000000000000000/example_normal.jpg",
"https://pbs.twimg.com/profile_images/1000000000000000000/example_normal.jpg"
],
"followers_context": "989 followers including @warriors",
"following": false,
"id": "TGlzdDo4NDgzOTQyMg==",
"id_str": "84839422",
"is_member": false,
"member_count": 81,
"members_context": "81 members",
"mode": "Public",
"muting": false,
"name": "Official Twitter Accounts",
"pinning": false,
"subscriber_count": 989,
"user_results": {
"result": {
"__typename": "User",
"affiliates_highlighted_label": {},
"avatar": {
"image_url": "https://pbs.twimg.com/profile_images/1955359038532653056/OSHY3ewP_normal.jpg"
},
"core": {
"created_at": "Tue Feb 20 14:35:54 +0000 2007",
"name": "X",
"screen_name": "X"
},
"dm_permissions": {
"can_dm": false
},
"follow_request_sent": false,
"has_graduated_access": true,
"id": "VXNlcjo3ODMyMTQ=",
"is_blue_verified": true,
"legacy": {
"default_profile": false,
"default_profile_image": false,
"description": "what's happening?!",
"entities": {
"description": {},
"url": {
"urls": [
{
"display_url": "x.com",
"expanded_url": "https://x.com",
"indices": [
0,
23
],
"url": "https://t.co/Xp0xJlcROt"
}
]
}
},
"fast_followers_count": 0,
"favourites_count": 5969,
"follow_request_sent": false,
"followers_count": 60685971,
"friends_count": 1,
"has_custom_timelines": true,
"is_translator": false,
"listed_count": 85171,
"media_count": 2492,
"needs_phone_verification": false,
"normal_followers_count": 60685971,
"notifications": false,
"possibly_sensitive": false,
"profile_banner_url": "https://pbs.twimg.com/profile_banners/783214/1690175171",
"profile_interstitial_type": "",
"statuses_count": 15727,
"time_zone": "",
"translator_type": "regular",
"url": "https://t.co/Xp0xJlcROt",
"utc_offset": 0,
"want_retweets": false,
"withheld_description": "",
"withheld_scope": ""
},
"location": {
"location": "everywhere"
},
"media_permissions": {
"can_media_tag": true
},
"parody_commentary_fan_label": "None",
"privacy": {
"protected": false
},
"professional": {
"category": [
{
"icon_name": "IconBriefcaseStroke",
"id": 714,
"name": "Technology Company"
}
],
"professional_type": "Business",
"rest_id": "1858538123375874167"
},
"profile_bio": {
"description": "what's happening?!"
},
"profile_description_language": "en",
"profile_image_shape": "Square",
"relationship_perspectives": {
"blocked_by": false,
"blocking": false,
"followed_by": false,
"following": false,
"muting": false
},
"rest_id": "783214",
"super_follow_eligible": false,
"super_followed_by": false,
"super_following": false,
"tipjar_settings": {},
"verification": {
"verified": false,
"verified_type": "Business"
}
}
}
}
},
"errors": [
{
"code": 214,
"extensions": {
"code": 214,
"kind": "Validation",
"name": "BadRequestError",
"source": "Client"
},
"kind": "Validation",
"locations": [
{
"column": 3,
"line": 65
}
],
"message": "BadRequest: com.twitter.strato.serialization.DecodeException",
"name": "BadRequestError",
"path": [
"list",
"default_banner_media_results",
"result"
],
"source": "Client"
}
]
}{
"data": {
"id": "84839422",
"name": "Official Twitter Accounts",
"description": "Accounts managed by Twitter, Inc.",
"createdAt": "2013-02-05T18:14:21Z",
"memberCount": 81,
"followerCount": 989,
"private": false,
"bannerUrl": "https://pbs.twimg.com/media/GkIQyCGWYAA4UdW.png",
"owner": {
"id": "783214",
"username": "X"
}
}
}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
- 400listId is missing or not numeric.
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, 408, 409 or a 5xx error are refunded.