Explore all defined operations, data models and types for this version. For live editing and client SDK generators, inspect on TypeHub.
Adds a Tweet to the authenticated user's Bookmarks.
Removes a Tweet from the authenticated user's Bookmarks.
Allows you to get an authenticated user's 800 most recent bookmarked Tweets.
Uploads a media file (base64 in JSON) for use in Tweets or Direct Messages. Use the returned id in media.media_ids when creating a Tweet.
Returns Quote Tweets for a Tweet specified by the requested Tweet ID.
Causes the authenticated user to Retweet the target Tweet.
Allows the authenticated user to undo a Retweet.
Returns the Retweets for a given Tweet ID.
Returns Tweets from the last seven days that match a search query.
The Trends lookup endpoint allow developers to get the Trends for a location, specified using the where-on-earth id (WOEID).
Creates a Tweet on behalf of an authenticated user.
Allows a user or authenticated user ID to delete a Tweet.
Returns a variety of information about a single Tweet specified by the requested ID.
Returns a variety of information about the Tweet specified by the requested ID or list of IDs.
Allows you to get information about a Tweet’s liking users.
Returns a list of users who have Retweeted the specified Tweet.
Hides or unhides a reply to a Tweet.
The Usage API in the Twitter API v2 allows developers to programmatically retrieve their project usage. Using thie endpoint, developers can keep a track and monitor of the number of Tweets they have pulled for a given billing cycle.
Causes the user ID identified in the path parameter to Like the target Tweet.
Returns a variety of information about one or more users specified by their usernames.
Allows the authenticated user to follow another user.
Returns a variety of information about a single user specified by the requested ID.
Returns a variety of information about one or more users specified by the requested IDs.
Returns information about a single user specified by their username.
Returns a list of users who are followers of the specified user ID.
Returns a list of users the specified user ID is following.
Tweets liked by a user
Returns information about an authorized user.
Returns Tweets mentioning a single user specified by the requested user ID.
Allows you to retrieve a collection of the most recent Tweets and Retweets posted by you and users you follow. This endpoint can return every Tweet created on a timeline over the last 7 days as well as the most recent 800 regardless of creation date.
Returns Tweets composed by a single user, specified by the requested user ID.
Allows a user or authenticated user ID to unlike a Tweet.
Allows the authenticated user to unfollow another user.
Result of a bookmark or remove bookmark action.
Response wrapper.
Metadata about a paginated collection response.
Request body to bookmark a Tweet.
A single error or problem entry returned by the X API, either as a partial error in a 200 response or inside an error response.
Error response of the X API. Contains the top-level problem fields and optionally a list of individual errors.
Field selection parameters which define the fields returned for each object type.
Result of a follow or unfollow action.
Follow/unfollow response wrapper.
Result of a hide or unhide reply action.
Response wrapper.
Objects referenced by the primary data and requested via the expansions parameter.
Result of a like or unlike action.
Response wrapper.
An image, video or animated GIF attached to a Tweet.
Public engagement metrics for the media.
An uploaded media object.
Image details of an uploaded media.
Asynchronous processing state of an uploaded media.
Request body for a one-shot media upload (JSON, base64).
Media upload response wrapper.
A playback or display variant of a media object.
Time range and pagination parameters for timeline and search endpoints.
A geographic place tagged in a Tweet.
A poll attached to a Tweet.
A choice in a poll.
Result of a Retweet or undo Retweet action.
Retweet response wrapper.
Request body referencing a single Tweet.
Request body referencing a target user.
A trending topic.
A list of trends.
Field selection for the trends endpoint.
Request body to create a Tweet.
The type of attachments (if any) present in this Tweet.
A list of Tweets.
The created Tweet.
Response wrapper.
Result of a Tweet deletion.
Response wrapper.
A Tweet (Post) object.
The location tagged on the Tweet, if the user provided one.
A GeoJSON Point geometry.
Indicates how much longer (if at all) this Tweet can be edited.
Options to edit an existing Tweet instead of creating a new one.
Entities (hashtags, cashtags, mentions, URLs) parsed from the Tweet text.
A user mention found in the Tweet text.
A hashtag or cashtag found in the Tweet text.
A URL found in the Tweet text.
A single Tweet response.
Location information for the Tweet being created.
Media attached to the Tweet being created.
The full content of a long Tweet (more than 280 characters).
Poll attached to the Tweet being created.
Public engagement metrics for the Tweet at the time of the request.
A Tweet that this Tweet refers to (Retweet, Quote or Reply).
Reply information for the Tweet being created.
Tweet consumption usage of the project for the current billing cycle.
Per client app daily Tweet usage.
Project-level daily Tweet usage.
A single day's Tweet usage entry.
Response wrapper.
Field selection for the usage endpoint.
An X user account.
A list of users.
A single user response.
Public metrics for this User.
Withholding details for withheld content.