---
name: twitter-openapi
description: "Twitter OpenAPI API skill. Use when working with Twitter OpenAPI for 1.1, 2, graphql. Covers 93 endpoints."
version: 1.0.0
generator: lapsh
---

# Twitter OpenAPI
API version: 0.0.1

## Auth
ApiKey Accept in header | ApiKey Accept-Encoding in header | ApiKey Accept-Language in header | ApiKey x-twitter-active-user in header | ApiKey x-twitter-auth-type in header | Bearer bearer | ApiKey x-twitter-client-language in header | ApiKey x-client-transaction-id in header | ApiKey x-client-uuid in header | ApiKey auth_token in cookie | ApiKey ct0 in cookie | ApiKey gt0 in cookie | ApiKey x-csrf-token in header | ApiKey x-guest-token in header | ApiKey Priority in header | ApiKey Referer in header | ApiKey Sec-Ch-Ua in header | ApiKey Sec-Ch-Ua-Mobile in header | ApiKey Sec-Ch-Ua-Platform in header | ApiKey Sec-Fetch-Dest in header | ApiKey Sec-Fetch-Mode in header | ApiKey Sec-Fetch-Site in header | ApiKey user-agent in header

## Base URL
https://x.com/i/api

## Setup
1. Set Authorization header with Bearer token
2. GET /1.1/friends/following/list.json -- get friends following list
3. POST /1.1/friendships/create.json -- create first create.json

## Endpoints
93 endpoints across 4 groups. See references/api-spec.lap for full details.

### 1.1
| Method | Path | Description |
|--------|------|-------------|
| GET | /1.1/friends/following/list.json | get friends following list |
| POST | /1.1/friendships/create.json | post create friendships |
| POST | /1.1/friendships/destroy.json | post destroy friendships |
| GET | /1.1/search/typeahead.json | get search typeahead |

### 2
| Method | Path | Description |
|--------|------|-------------|
| GET | /2/search/adaptive.json | get search adaptive |
| POST | /2/timeline/feedback.json | post timeline feedback |

### Graphql
| Method | Path | Description |
|--------|------|-------------|
| GET | /graphql/{pathQueryId}/AboutAccountQuery | About this account: join date, where the account is based, username changes, verification |
| GET | /graphql/{pathQueryId}/AudioSpaceById | a Space by id: metadata, participants and the announcing post |
| GET | /graphql/{pathQueryId}/AuthenticatePeriscope | a Periscope (live video) token for the account |
| GET | /graphql/{pathQueryId}/BirdwatchFetchAliasSelfSelectStatus | whether the account can pick / has picked a Community Notes alias |
| GET | /graphql/{pathQueryId}/BirdwatchFetchAuthenticatedUserProfile | the account's Community Notes profile |
| GET | /graphql/{pathQueryId}/BirdwatchFetchBirdwatchProfile | a Community Notes profile by alias |
| GET | /graphql/{pathQueryId}/BirdwatchFetchGlobalTimeline | the Community Notes home page (segmented timelines) |
| GET | /graphql/{pathQueryId}/BirdwatchFetchPublicData | download urls of the latest Community Notes public data files |
| GET | /graphql/{pathQueryId}/BlueVerifiedFollowers | get blue verified followers |
| GET | /graphql/{pathQueryId}/BookmarkSearchTimeline | search the account's bookmarks |
| GET | /graphql/{pathQueryId}/Bookmarks | get bookmarks |
| GET | /graphql/{pathQueryId}/BroadcastQuery | a live video broadcast by id |
| GET | /graphql/{pathQueryId}/CombinedLists | lists a user owns or follows |
| GET | /graphql/{pathQueryId}/CommunitiesFetchOneQuery | a community by id (community page) |
| GET | /graphql/{pathQueryId}/CommunitiesSearchQuery | search communities. cursor:[slice_info.next_cursor] |
| GET | /graphql/{pathQueryId}/CommunityAboutTimeline | get about of community |
| GET | /graphql/{pathQueryId}/CommunityDiscoveryTimeline | get the communities discovery timeline |
| GET | /graphql/{pathQueryId}/CommunityMediaTimeline | get media list of community |
| GET | /graphql/{pathQueryId}/CommunityQuery | a community by id (community settings and moderation pages) |
| GET | /graphql/{pathQueryId}/CommunityTweetsTimeline | get tweet list of community. rankingMode:[Recency, Relevance] |
| GET | /graphql/{pathQueryId}/ConnectTabTimeline | get the Connect tab (who to follow) timeline |
| POST | /graphql/{pathQueryId}/CreateBookmark | create Bookmark |
| POST | /graphql/{pathQueryId}/CreateDraftTweet | save a draft |
| POST | /graphql/{pathQueryId}/CreateList | create list |
| POST | /graphql/{pathQueryId}/CreateRetweet | create Retweet |
| POST | /graphql/{pathQueryId}/CreateTweet | create Tweet |
| GET | /graphql/{pathQueryId}/CreatorStudioTabBarItemQuery | audience rewards tasks shown in Creator Studio |
| GET | /graphql/{pathQueryId}/DataSaverMode | data saver setting of the account |
| POST | /graphql/{pathQueryId}/DeleteBookmark | delete Bookmark |
| POST | /graphql/{pathQueryId}/DeleteDraftTweets | delete drafts |
| POST | /graphql/{pathQueryId}/DeleteList | delete list |
| POST | /graphql/{pathQueryId}/DeleteRetweet | delete Retweet |
| POST | /graphql/{pathQueryId}/DeleteTweet | delete Retweet |
| GET | /graphql/{pathQueryId}/ExplorePage | get the explore page (segmented timelines) |
| GET | /graphql/{pathQueryId}/ExploreSidebar | the explore sidebar (trends) |
| POST | /graphql/{pathQueryId}/FavoriteTweet | favorite Tweet |
| GET | /graphql/{pathQueryId}/Favoriters | get tweet favoriters |
| GET | /graphql/{pathQueryId}/FetchDraftTweets | get drafts (unsent posts) |
| GET | /graphql/{pathQueryId}/FetchScheduledTweets | get scheduled posts |
| GET | /graphql/{pathQueryId}/Followers | get user list of followers |
| GET | /graphql/{pathQueryId}/FollowersYouKnow | get followers you know |
| GET | /graphql/{pathQueryId}/Following | get user list of following |
| GET | /graphql/{pathQueryId}/GenericTimelineById | get a generic timeline by its id (explore tabs) |
| GET | /graphql/{pathQueryId}/GlobalCommunitiesLatestPostSearchTimeline | search posts across communities (Latest) |
| GET | /graphql/{pathQueryId}/GlobalCommunitiesPostSearchTimeline | search posts across communities (Top) |
| GET | /graphql/{pathQueryId}/GrokHome | Grok home: model options, prompts and eligibility |
| GET | /graphql/{pathQueryId}/HomeLatestTimeline | get tweet list of timeline |
| GET | /graphql/{pathQueryId}/HomeTimeline | get tweet list of timeline |
| GET | /graphql/{pathQueryId}/Likes | get user likes tweets |
| POST | /graphql/{pathQueryId}/ListAddMember | add a member to a list |
| GET | /graphql/{pathQueryId}/ListByRestId | get list |
| GET | /graphql/{pathQueryId}/ListCreationRecommendedUsers | get recommended members while creating a list |
| GET | /graphql/{pathQueryId}/ListEditRecommendedUsers | get recommended members while editing a list |
| GET | /graphql/{pathQueryId}/ListLatestTweetsTimeline | get tweet list of timeline |
| GET | /graphql/{pathQueryId}/ListMembers | get list members |
| GET | /graphql/{pathQueryId}/ListOwnerships | get the lists a user owns (add/remove from Lists dialog) |
| POST | /graphql/{pathQueryId}/ListRemoveMember | remove a member from a list |
| GET | /graphql/{pathQueryId}/ListSearchTimeline | search lists |
| GET | /graphql/{pathQueryId}/ListSubscribers | get list subscribers (followers) |
| GET | /graphql/{pathQueryId}/ListsManagementPageTimeline | the account's lists management page |
| GET | /graphql/{pathQueryId}/NotificationsTimeline | get notification list. timeline_type:[All, Verified, Mentions] |
| GET | /graphql/{pathQueryId}/PinnedTimelines | the account's pinned timelines |
| GET | /graphql/{pathQueryId}/ProfileSpotlightsQuery | get user by screen name |
| GET | /graphql/{pathQueryId}/Retweeters | get tweet retweeters |
| GET | /graphql/{pathQueryId}/SearchTimeline | search tweet list. product:[Top, Latest, People, Photos, Videos] |
| GET | /graphql/{pathQueryId}/SidebarUserRecommendations | who to follow, shown in the sidebar of a profile |
| GET | /graphql/{pathQueryId}/TopicCarouselQuery | community topics and subtopics |
| GET | /graphql/{pathQueryId}/TweetDetail | get TweetDetail |
| GET | /graphql/{pathQueryId}/TweetResultByRestId | get TweetResultByRestId |
| POST | /graphql/{pathQueryId}/UnfavoriteTweet | unfavorite Tweet |
| GET | /graphql/{pathQueryId}/UserByRestId | get user by rest id. Deprecated: X answers 403 outside a browser since 2026-10 |
| GET | /graphql/{pathQueryId}/UserByScreenName | get user by screen name |
| GET | /graphql/{pathQueryId}/UserHighlightsTweets | get user highlights tweets |
| GET | /graphql/{pathQueryId}/UserMedia | get user media tweets |
| GET | /graphql/{pathQueryId}/UserOriginalsTimeline | get user tweets (profile posts tab) |
| GET | /graphql/{pathQueryId}/UserRepliesTimeline | get user tweets and replies (profile replies tab) |
| GET | /graphql/{pathQueryId}/UserRepostsTimeline | get user reposts (profile reposts tab) |
| GET | /graphql/{pathQueryId}/UserSuperFollowTweets | get user super follow tweets (subscriptions tab) |
| GET | /graphql/{pathQueryId}/UserTweets | get user tweets |
| GET | /graphql/{pathQueryId}/UserTweetsAndReplies | get user replies tweets |
| GET | /graphql/{pathQueryId}/UserVideoTimeline | get user media (profile media tab) |
| GET | /graphql/{pathQueryId}/UsersByRestIds | get users by rest ids. Deprecated: X answers 403 outside a browser since 2026-10 |
| GET | /graphql/{pathQueryId}/UsersVerifiedAvatars | verified-avatar users by ids |
| GET | /graphql/{pathQueryId}/ViewerBadgeCounts | get the unread badge counts of the viewer |
| GET | /graphql/{pathQueryId}/grokAccountJwtQuery | whether the account is linked to a Grok account |
| GET | /graphql/{pathQueryId}/useStoryTopicQuery | AI-written stories of an explore topic (rest_id: For You) |

### Other
| Method | Path | Description |
|--------|------|-------------|
| GET | /other | This is not an actual endpoint |

## Common Questions
Match user requests to endpoints in references/api-spec.lap. Key patterns:
- "List all list.json?" -> GET /1.1/friends/following/list.json
- "Create a create.json?" -> POST /1.1/friendships/create.json
- "Create a destroy.json?" -> POST /1.1/friendships/destroy.json
- "Search typeahead.json?" -> GET /1.1/search/typeahead.json
- "Search adaptive.json?" -> GET /2/search/adaptive.json
- "Create a feedback.json?" -> POST /2/timeline/feedback.json
- "List all AboutAccountQuery?" -> GET /graphql/{pathQueryId}/AboutAccountQuery
- "List all AudioSpaceById?" -> GET /graphql/{pathQueryId}/AudioSpaceById
- "List all AuthenticatePeriscope?" -> GET /graphql/{pathQueryId}/AuthenticatePeriscope
- "List all BirdwatchFetchAliasSelfSelectStatus?" -> GET /graphql/{pathQueryId}/BirdwatchFetchAliasSelfSelectStatus
- "List all BirdwatchFetchAuthenticatedUserProfile?" -> GET /graphql/{pathQueryId}/BirdwatchFetchAuthenticatedUserProfile
- "List all BirdwatchFetchBirdwatchProfile?" -> GET /graphql/{pathQueryId}/BirdwatchFetchBirdwatchProfile
- "List all BirdwatchFetchGlobalTimeline?" -> GET /graphql/{pathQueryId}/BirdwatchFetchGlobalTimeline
- "List all BirdwatchFetchPublicData?" -> GET /graphql/{pathQueryId}/BirdwatchFetchPublicData
- "List all BlueVerifiedFollowers?" -> GET /graphql/{pathQueryId}/BlueVerifiedFollowers
- "List all BookmarkSearchTimeline?" -> GET /graphql/{pathQueryId}/BookmarkSearchTimeline
- "List all Bookmarks?" -> GET /graphql/{pathQueryId}/Bookmarks
- "List all BroadcastQuery?" -> GET /graphql/{pathQueryId}/BroadcastQuery
- "List all CombinedLists?" -> GET /graphql/{pathQueryId}/CombinedLists
- "List all CommunitiesFetchOneQuery?" -> GET /graphql/{pathQueryId}/CommunitiesFetchOneQuery
- "List all CommunitiesSearchQuery?" -> GET /graphql/{pathQueryId}/CommunitiesSearchQuery
- "List all CommunityAboutTimeline?" -> GET /graphql/{pathQueryId}/CommunityAboutTimeline
- "List all CommunityDiscoveryTimeline?" -> GET /graphql/{pathQueryId}/CommunityDiscoveryTimeline
- "List all CommunityMediaTimeline?" -> GET /graphql/{pathQueryId}/CommunityMediaTimeline
- "List all CommunityQuery?" -> GET /graphql/{pathQueryId}/CommunityQuery
- "List all CommunityTweetsTimeline?" -> GET /graphql/{pathQueryId}/CommunityTweetsTimeline
- "List all ConnectTabTimeline?" -> GET /graphql/{pathQueryId}/ConnectTabTimeline
- "Create a CreateBookmark?" -> POST /graphql/{pathQueryId}/CreateBookmark
- "Create a CreateDraftTweet?" -> POST /graphql/{pathQueryId}/CreateDraftTweet
- "Create a CreateList?" -> POST /graphql/{pathQueryId}/CreateList
- "Create a CreateRetweet?" -> POST /graphql/{pathQueryId}/CreateRetweet
- "Create a CreateTweet?" -> POST /graphql/{pathQueryId}/CreateTweet
- "List all CreatorStudioTabBarItemQuery?" -> GET /graphql/{pathQueryId}/CreatorStudioTabBarItemQuery
- "List all DataSaverMode?" -> GET /graphql/{pathQueryId}/DataSaverMode
- "Create a DeleteBookmark?" -> POST /graphql/{pathQueryId}/DeleteBookmark
- "Create a DeleteDraftTweet?" -> POST /graphql/{pathQueryId}/DeleteDraftTweets
- "Create a DeleteList?" -> POST /graphql/{pathQueryId}/DeleteList
- "Create a DeleteRetweet?" -> POST /graphql/{pathQueryId}/DeleteRetweet
- "Create a DeleteTweet?" -> POST /graphql/{pathQueryId}/DeleteTweet
- "List all ExplorePage?" -> GET /graphql/{pathQueryId}/ExplorePage
- "List all ExploreSidebar?" -> GET /graphql/{pathQueryId}/ExploreSidebar
- "Create a FavoriteTweet?" -> POST /graphql/{pathQueryId}/FavoriteTweet
- "List all Favoriters?" -> GET /graphql/{pathQueryId}/Favoriters
- "List all FetchDraftTweets?" -> GET /graphql/{pathQueryId}/FetchDraftTweets
- "List all FetchScheduledTweets?" -> GET /graphql/{pathQueryId}/FetchScheduledTweets
- "List all Followers?" -> GET /graphql/{pathQueryId}/Followers
- "List all FollowersYouKnow?" -> GET /graphql/{pathQueryId}/FollowersYouKnow
- "List all Following?" -> GET /graphql/{pathQueryId}/Following
- "List all GenericTimelineById?" -> GET /graphql/{pathQueryId}/GenericTimelineById
- "List all GlobalCommunitiesLatestPostSearchTimeline?" -> GET /graphql/{pathQueryId}/GlobalCommunitiesLatestPostSearchTimeline
- "List all GlobalCommunitiesPostSearchTimeline?" -> GET /graphql/{pathQueryId}/GlobalCommunitiesPostSearchTimeline
- "List all GrokHome?" -> GET /graphql/{pathQueryId}/GrokHome
- "List all HomeLatestTimeline?" -> GET /graphql/{pathQueryId}/HomeLatestTimeline
- "List all HomeTimeline?" -> GET /graphql/{pathQueryId}/HomeTimeline
- "List all Likes?" -> GET /graphql/{pathQueryId}/Likes
- "Create a ListAddMember?" -> POST /graphql/{pathQueryId}/ListAddMember
- "List all ListByRestId?" -> GET /graphql/{pathQueryId}/ListByRestId
- "List all ListCreationRecommendedUsers?" -> GET /graphql/{pathQueryId}/ListCreationRecommendedUsers
- "List all ListEditRecommendedUsers?" -> GET /graphql/{pathQueryId}/ListEditRecommendedUsers
- "List all ListLatestTweetsTimeline?" -> GET /graphql/{pathQueryId}/ListLatestTweetsTimeline
- "List all ListMembers?" -> GET /graphql/{pathQueryId}/ListMembers
- "List all ListOwnerships?" -> GET /graphql/{pathQueryId}/ListOwnerships
- "Create a ListRemoveMember?" -> POST /graphql/{pathQueryId}/ListRemoveMember
- "List all ListSearchTimeline?" -> GET /graphql/{pathQueryId}/ListSearchTimeline
- "List all ListSubscribers?" -> GET /graphql/{pathQueryId}/ListSubscribers
- "List all ListsManagementPageTimeline?" -> GET /graphql/{pathQueryId}/ListsManagementPageTimeline
- "List all NotificationsTimeline?" -> GET /graphql/{pathQueryId}/NotificationsTimeline
- "List all PinnedTimelines?" -> GET /graphql/{pathQueryId}/PinnedTimelines
- "List all ProfileSpotlightsQuery?" -> GET /graphql/{pathQueryId}/ProfileSpotlightsQuery
- "List all Retweeters?" -> GET /graphql/{pathQueryId}/Retweeters
- "List all SearchTimeline?" -> GET /graphql/{pathQueryId}/SearchTimeline
- "List all SidebarUserRecommendations?" -> GET /graphql/{pathQueryId}/SidebarUserRecommendations
- "List all TopicCarouselQuery?" -> GET /graphql/{pathQueryId}/TopicCarouselQuery
- "List all TweetDetail?" -> GET /graphql/{pathQueryId}/TweetDetail
- "List all TweetResultByRestId?" -> GET /graphql/{pathQueryId}/TweetResultByRestId
- "Create a UnfavoriteTweet?" -> POST /graphql/{pathQueryId}/UnfavoriteTweet
- "List all UserByRestId?" -> GET /graphql/{pathQueryId}/UserByRestId
- "List all UserByScreenName?" -> GET /graphql/{pathQueryId}/UserByScreenName
- "List all UserHighlightsTweets?" -> GET /graphql/{pathQueryId}/UserHighlightsTweets
- "List all UserMedia?" -> GET /graphql/{pathQueryId}/UserMedia
- "List all UserOriginalsTimeline?" -> GET /graphql/{pathQueryId}/UserOriginalsTimeline
- "List all UserRepliesTimeline?" -> GET /graphql/{pathQueryId}/UserRepliesTimeline
- "List all UserRepostsTimeline?" -> GET /graphql/{pathQueryId}/UserRepostsTimeline
- "List all UserSuperFollowTweets?" -> GET /graphql/{pathQueryId}/UserSuperFollowTweets
- "List all UserTweets?" -> GET /graphql/{pathQueryId}/UserTweets
- "List all UserTweetsAndReplies?" -> GET /graphql/{pathQueryId}/UserTweetsAndReplies
- "List all UserVideoTimeline?" -> GET /graphql/{pathQueryId}/UserVideoTimeline
- "List all UsersByRestIds?" -> GET /graphql/{pathQueryId}/UsersByRestIds
- "List all UsersVerifiedAvatars?" -> GET /graphql/{pathQueryId}/UsersVerifiedAvatars
- "List all ViewerBadgeCounts?" -> GET /graphql/{pathQueryId}/ViewerBadgeCounts
- "List all grokAccountJwtQuery?" -> GET /graphql/{pathQueryId}/grokAccountJwtQuery
- "List all useStoryTopicQuery?" -> GET /graphql/{pathQueryId}/useStoryTopicQuery
- "List all other?" -> GET /other
- "How to authenticate?" -> See Auth section above

## Response Tips
- Check response schemas in references/api-spec.lap for field details
- Paginated endpoints accept limit/offset or cursor parameters
- Create/update endpoints return the modified resource on success

## References
- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas

> Generated from the official API spec by [LAP](https://lap.sh)
