{"openapi":"3.1.0","info":{"title":"TwittrAPI API","version":"1.0.0","summary":"Public Twitter/X data over REST, priced per API call.","description":"TwittrAPI is a REST API for public Twitter/X data: users, tweets, search, followers, lists, communities, jobs and trends. Pay per call from a prepaid balance; no X developer account needed.\n\nAuthentication: send your key in the X-API-KEY header. Get a key at https://www.twittrapi.com/start (a human signs up; the key can then be given to an agent).\n\nResponses: X's raw JSON by default (passthrough), or add format=simple for compact, flat JSON with a fixed schema (same price).\n\nPricing (machine-readable): https://www.twittrapi.com/pricing.json. All docs in one file: https://www.twittrapi.com/llms-full.txt.\n\nRapidAPI: the same paths on https://twitter-aio.p.rapidapi.com with the x-rapidapi-key and x-rapidapi-host headers.\n\nNot affiliated with X Corp. Twitter and X are trademarks of X Corp. Only publicly available data is accessible.","contact":{"name":"TwittrAPI support","email":"support@twittrapi.com","url":"https://www.twittrapi.com/docs"},"termsOfService":"https://www.twittrapi.com/terms","license":{"name":"Proprietary: use under the terms of service","url":"https://www.twittrapi.com/terms"}},"externalDocs":{"description":"Documentation","url":"https://www.twittrapi.com/docs"},"servers":[{"url":"https://api.twittrapi.com","description":"Direct API"},{"url":"https://twitter-aio.p.rapidapi.com","description":"RapidAPI (x-rapidapi-key and x-rapidapi-host headers instead of X-API-KEY)"}],"security":[{"ApiKeyAuth":[]}],"tags":[{"name":"Search","description":"Search endpoints (read-only GET)."},{"name":"Tweets","description":"Tweets endpoints (read-only GET)."},{"name":"Users","description":"Users endpoints (read-only GET)."},{"name":"Communities","description":"Communities endpoints (read-only GET)."},{"name":"Lists","description":"Lists endpoints (read-only GET)."},{"name":"Jobs","description":"Jobs endpoints (read-only GET)."},{"name":"Trends","description":"Trends endpoints (read-only GET)."},{"name":"Misc","description":"Misc endpoints (read-only GET)."},{"name":"Account actions","description":"POST endpoints that act on your own X account with your session cookie and your own proxy. Never retried by the gateway."},{"name":"Account","description":"Your TwittrAPI key and balance."}],"paths":{"/search":{"get":{"operationId":"search","summary":"Search tweets","description":"Search tweets or people with the same query syntax as the X search box.\n\nThis is the Search tab of X. The query supports X search operators, and the optional filters object adds operators for you. Results come one page at a time.\n\nAlso answers on: POST /search (same handler; the request body is ignored, parameters go in the query string); GET /search/{searchItem} (query as a URL-encoded path segment instead of ?searchItem); POST /search/{searchItem}; GET /search_v2 (same, but skips the control-character check); POST /search_v2.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nAn empty timeline from X is retried with other accounts, up to 9 upstream calls. You are billed once.\n\nMutually exclusive filter pairs (for example removeReplies and onlyReplies) return 422 when both are true.\n\nReference: https://www.twittrapi.com/docs/reference/search","tags":["Search"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/search"},"parameters":[{"name":"searchItem","in":"query","required":true,"description":"Search query, e.g. from:jack lang:en. Required unless filters is set. query is accepted as an alias. When the query contains operators, + is read as a space. Query plus filters may be at most 512 characters.","schema":{"type":"string","maxLength":512}},{"name":"category","in":"query","required":false,"description":"Search tab: Top, Latest, People, Photos or Videos. Any other value is treated as Top.","schema":{"type":"string","default":"Top","enum":["Top","Latest","People","Photos","Videos"]}},{"name":"count","in":"query","required":false,"description":"Number of results to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"filters","in":"query","required":false,"description":"Extra conditions as JSON, e.g. {\"lang\":\"en\",\"minimumLikesCount\":100}. Each key becomes an operator that is appended to the query. Keys are listed below.","schema":{"type":"string","contentMediaType":"application/json"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Not the raw GraphQL object: {\"category\": \"<tab>\", \"entries\": [...]}, where entries is the instructions array of X's SearchTimeline (data.search_by_raw_query.search_timeline.timeline.instructions). Tweets and users are inside TimelineAddEntries; the bottom cursor is an entry with cursorType \"Bottom\".\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. With category=People: User objects.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"Query and filters are both empty, or filters is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"The query has control characters (not checked on /search_v2), is longer than 512 characters, contains [ or ], has an unclosed double quote or unbalanced parentheses, uses an unsupported operator, or a filters value has the wrong format. X validation errors also return 422.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"502":{"description":"X returned an empty timeline 9 times in a row. Body: {\"error\": \"...\", \"attempts\": 9}. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/tweet/{tweetId}":{"get":{"operationId":"tweetTweetid","summary":"Tweet with replies","description":"A tweet with its author, media, counts and the reply thread.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/tweet-tweetid","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/tweet-tweetid"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"rankingMode","in":"query","required":false,"description":"Order of the replies, passed to X: Relevance, Recency or Likes.","schema":{"type":"string","default":"Relevance","enum":["Relevance","Recency","Likes"]}},{"name":"includePromotedContent","in":"query","required":false,"description":"Ask X to include promoted tweets. Accepts true/false, 1/0.","schema":{"type":"boolean","default":false}},{"name":"cursor","in":"query","required":false,"description":"Cursor from the previous page to load more replies.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's TweetDetail query. The focal tweet and replies are entries in data.threaded_conversation_with_injections_v2.instructions. X sends about 20 to 35 reply threads (conversationthread entries) per page; the page size is fixed. The bottom cursor is an entry with cursorType \"Bottom\" at the end of the entries.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. The conversation in display order: ancestors, the tweet itself, then replies; threads (modules) are flattened.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"X reports the tweet as not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/simpletweet/{tweetId}":{"get":{"operationId":"simpletweetTweetid","summary":"Single tweet","description":"One tweet by ID, without the reply thread. Smaller than /tweet/{tweetId}.\n\nReference: https://www.twittrapi.com/docs/reference/simpletweet-tweetid","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/simpletweet-tweetid"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's TweetResultByRestId query (data.tweetResult.result).\n\nWith format=simple: {data: Tweet}, or {data: {id, unavailable: true}} when X does not return the tweet.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"X reports the tweet as not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/tweet/{tweetId}/article":{"get":{"operationId":"tweetTweetidArticle","summary":"Tweet with article content","description":"Like /tweet/{tweetId}, but also asks X for the full content of an X Article attached to the tweet.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/tweet-tweetid-article","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/tweet-tweetid-article"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"rankingMode","in":"query","required":false,"description":"Order of the replies, passed to X: Relevance, Recency or Likes.","schema":{"type":"string","default":"Relevance","enum":["Relevance","Recency","Likes"]}},{"name":"includePromotedContent","in":"query","required":false,"description":"Ask X to include promoted tweets. Accepts true/false, 1/0.","schema":{"type":"boolean","default":false}},{"name":"cursor","in":"query","required":false,"description":"Cursor from the previous page to load more replies.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's TweetDetail query with the article fields turned on. For a tweet without an X Article the response is the same as /tweet/{tweetId}.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. Like the tweet detail; the article is in the tweet's article field (id, title, previewText, coverImageUrl, publishedAt, text).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"X reports the tweet as not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/tweet/{tweetId}/favorites":{"get":{"operationId":"tweetTweetidFavorites","summary":"Users who liked a tweet","description":"Accounts that liked a tweet.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nX made likes private in June 2024: only the author of a tweet can see who liked it. The API does not read as the author, so the timeline is empty: the only instruction is TimelineTerminateTimeline, with no entries and no cursor. The like count is still in the tweet (favorite_count).\n\nReference: https://www.twittrapi.com/docs/reference/tweet-tweetid-favorites","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/tweet-tweetid-favorites"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"count","in":"query","required":false,"description":"Number of users to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's Favoriters query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/tweet/{tweetId}/retweets":{"get":{"operationId":"tweetTweetidRetweets","summary":"Users who retweeted a tweet","description":"Accounts that retweeted a tweet.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/tweet-tweetid-retweets","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/tweet-tweetid-retweets"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"count","in":"query","required":false,"description":"Number of users to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"rankingMode","in":"query","required":false,"description":"Recency turns X's ranking off. Any other value, or none, keeps it on.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's Retweeters query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/tweet/{tweetId}/quotes":{"get":{"operationId":"tweetTweetidQuotes","summary":"Quote tweets","description":"Tweets that quote a tweet.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/tweet-tweetid-quotes","tags":["Tweets"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/tweet-tweetid-quotes"},"parameters":[{"name":"tweetId","in":"path","required":true,"description":"Numeric tweet ID (digits only, up to 30), the number at the end of the tweet URL.","schema":{"type":"string","pattern":"^[0-9]{1,30}$"}},{"name":"count","in":"query","required":false,"description":"Number of tweets to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"rankingMode","in":"query","required":false,"description":"Recency returns the newest quotes first (Latest tab). Anything else uses the Top tab.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's SearchTimeline for quoted_tweet_id:<tweetId>. Unlike /search, it is not wrapped in {category, entries}.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. Each item quotes the tweet (quoted).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"tweetId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/by/username/{username}":{"get":{"operationId":"userByUsernameUsername","summary":"User by username","description":"Profile of one account by handle, including its numeric user ID.\n\nReference: https://www.twittrapi.com/docs/reference/user-by-username-username","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-by-username-username"},"parameters":[{"name":"username","in":"path","required":true,"description":"Handle, with or without a leading @. 2 to 15 characters: letters, digits and underscore.","schema":{"type":"string","pattern":"^@?[A-Za-z0-9_]{2,15}$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserByScreenName query (data.user.result, with rest_id and legacy profile fields). When X returns no user, the API answers 200 with {\"data\": {}, \"userExists\": false}.\n\nWith format=simple: {data: User}, or {data: null} when the handle does not exist.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"The username contains characters X blocks, or X returned an error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"The username is not 2 to 15 letters, digits or underscores.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}":{"get":{"operationId":"userUserid","summary":"User by ID","description":"Profile of one account by numeric user ID.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserByRestId query (data.user.result).\n\nWith format=simple: {data: User}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"X reports the user as not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/users/by/ids":{"get":{"operationId":"userUsersByIds","summary":"Users by IDs","description":"Profiles of up to 100 accounts in one call.\n\nReference: https://www.twittrapi.com/docs/reference/user-users-by-ids","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-users-by-ids"},"parameters":[{"name":"ids","in":"query","required":true,"description":"Numeric user IDs separated by commas. At most 100.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"},"maxItems":100}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UsersByRestIds query (data.users, one result per ID).\n\nWith format=simple: Collection of User objects without cursors (hasNextPage false). Accounts X does not return are left out.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"ids is missing, or has more than 100 IDs.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"One of the IDs is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/usernames/to/ids":{"get":{"operationId":"userUsernamesToIds","summary":"Usernames to IDs","description":"Numeric user IDs for up to 100 handles in one call.\n\nReference: https://www.twittrapi.com/docs/reference/user-usernames-to-ids","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-usernames-to-ids"},"parameters":[{"name":"usernames","in":"query","required":true,"description":"Handles separated by commas, with or without @. At most 100.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"},"maxItems":100}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Built by the API: {\"userIds\": {\"jack\": \"12\", ...}}. Only resolved handles are keys of userIds. A handle that could not be resolved is left out of userIds and listed in errors: [{\"username\": \"...\", \"error\": \"not_found\" | \"suspended\" | \"upstream_error\", \"message\": \"...\"}]. errors is left out when every handle resolved. upstream_error means X could not be asked (retry later), not that the account is missing.\n\nWith format=simple: Unchanged inside {data: ...}: {userIds, errors} is already small, so the simple format only adds the envelope.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/DataPassthrough"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"usernames is missing, has more than 100 entries, or a handle contains characters X blocks.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"A handle is not 2 to 15 letters, digits or underscores.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/username/to/id/{username}":{"get":{"operationId":"usernameToIdUsername","summary":"Username to ID","description":"Numeric user ID for one handle. Smaller response than the full profile.\n\nReference: https://www.twittrapi.com/docs/reference/username-to-id-username","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/username-to-id-username"},"parameters":[{"name":"username","in":"path","required":true,"description":"Handle, with or without a leading @. 2 to 15 characters: letters, digits and underscore.","schema":{"type":"string","pattern":"^@?[A-Za-z0-9_]{2,15}$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Built by the API: {\"userId\": \"12\"}.\n\nWith format=simple: Unchanged inside {data: ...}: {userId} is already small, so the simple format only adds the envelope.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/DataPassthrough"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"The username contains characters X blocks, or X returned an error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"The username is invalid, or no user was found (body has errorInfo with X's response).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/about/{username}":{"get":{"operationId":"userAboutUsername","summary":"About this account","description":"The data behind X's \"About this account\" panel (account location, join date, username changes and similar).\n\nReference: https://www.twittrapi.com/docs/reference/user-about-username","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-about-username"},"parameters":[{"name":"username","in":"path","required":true,"description":"Handle, with or without a leading @. 2 to 15 characters: letters, digits and underscore.","schema":{"type":"string","pattern":"^@?[A-Za-z0-9_]{2,15}$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's AboutAccountQuery.\n\nWith format=simple: {data: User with an about object}: accountBasedIn, locationAccurate, createdCountryAccurate, source, usernameChanges, lastUsernameChangeAt, affiliateUsername, identityVerified, verifiedSince. X sends no counts here, so counts are 0.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserAboutResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"The username is not 2 to 15 letters, digits or underscores.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/tweets":{"get":{"operationId":"userUseridTweets","summary":"User tweets","description":"Tweets from a profile timeline (without replies), newest first.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-tweets","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-tweets"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"includePromotedContent","in":"query","required":false,"description":"Ask X to include promoted tweets. Accepts true/false, 1/0.","schema":{"type":"boolean","default":false}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserTweets query. Entries are in data.user.result.timeline.timeline.instructions.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. The pinned tweet comes first with isPinned: true. \"Who to follow\" modules are dropped.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/tweetsAndReplies":{"get":{"operationId":"userUseridTweetsandreplies","summary":"User tweets and replies","description":"Tweets and replies from a profile, newest first.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-tweetsandreplies","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-tweetsandreplies"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserTweetsAndReplies query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/media":{"get":{"operationId":"userUseridMedia","summary":"User media","description":"Tweets with photos or videos from a profile.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-media","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-media"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserMedia query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/likes":{"get":{"operationId":"userUseridLikes","summary":"User likes","description":"Tweets a user has liked.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nX made likes private in June 2024 and shows them only to the account owner. The API does not read as the owner, so the result is empty: {\"data\": {\"user\": {\"result\": {\"__typename\": \"User\", \"timeline\": {}}}}}, without instructions or cursor.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-likes","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-likes"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's Likes query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. Empty since X made likes private: {data: [], nextCursor: null}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/followers":{"get":{"operationId":"userUseridFollowers","summary":"Followers","description":"Accounts that follow a user, newest first.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-followers","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-followers"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's Followers query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/followings":{"get":{"operationId":"userUseridFollowings","summary":"Following","description":"Accounts a user follows.\n\nAlso answers on: GET /user/{userId}/following (same handler).\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-followings","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-followings"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's Following query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/verifiedFollowers":{"get":{"operationId":"userUseridVerifiedfollowers","summary":"Verified followers","description":"Followers of a user that have a verified (blue) badge.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-verifiedfollowers","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-verifiedfollowers"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's BlueVerifiedFollowers query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/{userId}/articles":{"get":{"operationId":"userUseridArticles","summary":"User articles","description":"X Articles (long-form posts) published by a user.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nAn entry can have an empty tweet_results ({}) when X no longer returns that article (deleted or restricted). Skip such entries.\n\nReference: https://www.twittrapi.com/docs/reference/user-userid-articles","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-userid-articles"},"parameters":[{"name":"userId","in":"path","required":true,"description":"Numeric user ID (digits only, up to 30). To pass a handle instead, use -1 here and set username.","schema":{"type":"string","pattern":"^(-1|[0-9]{1,30})$"}},{"name":"username","in":"query","required":false,"description":"Handle, 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.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of items to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"includePromotedContent","in":"query","required":false,"description":"Ask X to include promoted tweets. Accepts true/false, 1/0.","schema":{"type":"boolean","default":true}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's UserArticlesTweets query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. Each item carries its article (title, previewText, coverImageUrl, publishedAt).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"userId is -1 and username is missing, the username contains characters X blocks, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"userId is not numeric, or the username lookup failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/usernames/status":{"get":{"operationId":"userUsernamesStatus","summary":"Account status for many handles","description":"Whether each handle is active, suspended, protected or not found. Up to 500 handles per call.\n\nReference: https://www.twittrapi.com/docs/reference/user-usernames-status","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-usernames-status"},"parameters":[{"name":"usernames","in":"query","required":true,"description":"Handles separated by commas, with or without @. At most 500.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"},"maxItems":500}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Built by the API: {\"usernamesStatus\": {\"jack\": \"active\", ...}}. Values: active, suspended, protected, not-found, or error when X could not be asked. For each error there is also an entry in errors: [{\"username\": \"...\", \"error\": \"upstream_error\", \"message\": \"...\"}]; errors is left out when there are none.\n\nWith format=simple: Unchanged inside {data: ...}: {usernamesStatus, errors} is already small, so the simple format only adds the envelope.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/DataPassthrough"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"usernames is missing or has more than 500 entries.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/user/friendships/show":{"get":{"operationId":"userFriendshipsShow","summary":"Relationship between two accounts","description":"Whether one account follows another, and the other way round.\n\nReference: https://www.twittrapi.com/docs/reference/user-friendships-show","tags":["Users"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/user-friendships-show"},"parameters":[{"name":"source_screen_name","in":"query","required":true,"description":"First handle, with or without @.","schema":{"type":"string"}},{"name":"target_screen_name","in":"query","required":true,"description":"Second handle, with or without @.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's v1.1 friendships/show endpoint: relationship.source and relationship.target with following and followed_by.\n\nWith format=simple: {data: {source: {id, username}, target: {id, username}, following, followedBy, canDm, blocking, blockedBy, muting}}. following: source follows target.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/FriendshipResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"One of the two handles is missing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"One of the two handles is not 2 to 15 letters, digits or underscores.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/search/{searchTerm}":{"get":{"operationId":"communitiesSearchSearchterm","summary":"Search communities","description":"Find X Communities by keyword.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/communities-search-searchterm","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-search-searchterm"},"parameters":[{"name":"searchTerm","in":"path","required":true,"description":"Keyword, URL-encoded.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of communities to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"sort","in":"query","required":false,"description":"Sort order, passed to X as is.","schema":{"type":"string","default":"Relevance"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's CommunitiesSearchQuery. Communities are in data.communities_search_slice.items_results; the next-page cursor is data.communities_search_slice.slice_info.next_cursor (there are no cursor entries).\n\nWith format=simple: Collection of Community objects (description and rules are empty in search results).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CommunityPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/{communityId}":{"get":{"operationId":"communitiesCommunityid","summary":"Community details","description":"Name, description, rules, member count and admins of a community.\n\nReference: https://www.twittrapi.com/docs/reference/communities-communityid","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-communityid"},"parameters":[{"name":"communityId","in":"path","required":true,"description":"Numeric community ID, the number in the community URL.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's CommunityQuery.\n\nWith format=simple: {data: Community}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CommunityResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"communityId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/{communityId}/tweets":{"get":{"operationId":"communitiesCommunityidTweets","summary":"Community tweets","description":"Tweets posted in a community.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/communities-communityid-tweets","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-communityid-tweets"},"parameters":[{"name":"communityId","in":"path","required":true,"description":"Numeric community ID, the number in the community URL.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of tweets to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's CommunityTweetsTimeline query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"communityId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/{communityId}/members":{"get":{"operationId":"communitiesCommunityidMembers","summary":"Community members","description":"Members of a community.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/communities-communityid-members","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-communityid-members"},"parameters":[{"name":"communityId","in":"path","required":true,"description":"Numeric community ID, the number in the community URL.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of members to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's membersSliceTimeline_Query. Members are in data.communityResults.result.members_slice.items_results; the next-page cursor is members_slice.slice_info.next_cursor.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"communityId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/{communityId}/members/search":{"get":{"operationId":"communitiesCommunityidMembersSearch","summary":"Search community members","description":"Find members of a community whose handle matches a text.\n\nReference: https://www.twittrapi.com/docs/reference/communities-communityid-members-search","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-communityid-members-search"},"parameters":[{"name":"communityId","in":"path","required":true,"description":"Numeric community ID, the number in the community URL.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"username","in":"query","required":true,"description":"Text to match, with or without @.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's CommunityMemberRelationshipTypeahead query. Not paginated.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"username is missing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"communityId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/communities/{communityId}/moderators":{"get":{"operationId":"communitiesCommunityidModerators","summary":"Community moderators","description":"Moderators and admins of a community.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/communities-communityid-moderators","tags":["Communities"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/communities-communityid-moderators"},"parameters":[{"name":"communityId","in":"path","required":true,"description":"Numeric community ID, the number in the community URL.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of moderators to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's moderatorsSliceTimeline_Query. Moderators are in data.communityResults.result.moderators_slice.items_results; slice_info has a next_cursor only when there is another page.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"communityId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/lists/details":{"get":{"operationId":"listsDetails","summary":"List details","description":"Name, description, owner and member and subscriber counts of a list.\n\nReference: https://www.twittrapi.com/docs/reference/lists-details","tags":["Lists"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/lists-details"},"parameters":[{"name":"listId","in":"query","required":true,"description":"Numeric list ID, the number in the list URL (x.com/i/lists/<listId>).","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"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.\n\nWith format=simple: {data: List}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ListResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"listId is missing or not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/lists/tweets":{"get":{"operationId":"listsTweets","summary":"List tweets","description":"Tweets from the members of a list, newest first.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/lists-tweets","tags":["Lists"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/lists-tweets"},"parameters":[{"name":"listId","in":"query","required":true,"description":"Numeric list ID, the number in the list URL (x.com/i/lists/<listId>).","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of tweets to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's ListLatestTweetsTimeline query.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TweetPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"listId is missing or not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/lists/members":{"get":{"operationId":"listsMembers","summary":"List members","description":"Accounts that are members of a list.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/lists-members","tags":["Lists"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/lists-members"},"parameters":[{"name":"listId","in":"query","required":true,"description":"Numeric list ID, the number in the list URL (x.com/i/lists/<listId>).","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of members to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's ListMembers query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"listId is missing or not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/lists/followers":{"get":{"operationId":"listsFollowers","summary":"List followers","description":"Accounts that follow (subscribe to) a list.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/reference/lists-followers","tags":["Lists"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/lists-followers"},"parameters":[{"name":"listId","in":"query","required":true,"description":"Numeric list ID, the number in the list URL (x.com/i/lists/<listId>).","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"count","in":"query","required":false,"description":"Number of followers to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's ListSubscribers query.\n\nWith format=simple: Collection of User objects: {data: [User], nextCursor, previousCursor, hasNextPage}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UserPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"listId is missing or not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/jobs/search/{searchTerm}":{"get":{"operationId":"jobsSearchSearchterm","summary":"Search jobs","description":"Job listings posted on X, by keyword.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nX's job search sometimes fails on X's side (DependencyError); the API retries with other accounts and returns an error if every attempt fails. Retrying a little later usually works.\n\nReference: https://www.twittrapi.com/docs/reference/jobs-search-searchterm","tags":["Jobs"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/jobs-search-searchterm"},"parameters":[{"name":"searchTerm","in":"path","required":true,"description":"Keyword, URL-encoded.","schema":{"type":"string"}},{"name":"count","in":"query","required":false,"description":"Number of jobs to ask X for. Sent to X as is; X treats it as a hint and decides how many it returns (follower and following pages often hold 50 to 70 users for count=20). A value that is not a number falls back to 20.","schema":{"type":"integer","default":20}},{"name":"cursor","in":"query","required":false,"description":"Bottom cursor from the previous page. Leave it out for the first page. See Pagination.","schema":{"type":"string"}},{"name":"jobLocationId","in":"query","required":false,"description":"Location IDs from /jobs/find-location/{term}.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"jobLocationType","in":"query","required":false,"description":"Location types, passed to X unchanged.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"seniorityLevel","in":"query","required":false,"description":"Seniority levels, passed to X unchanged.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"employmentType","in":"query","required":false,"description":"Employment types, passed to X unchanged.","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"companyName","in":"query","required":false,"description":"Only jobs from this company.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's JobSearchQueryScreenJobsQuery. Jobs are in data.job_search.items_results; the next-page cursor is data.job_search.slice_info.next_cursor.\n\nWith format=simple: Collection of Job objects.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/JobPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/jobs/{jobId}":{"get":{"operationId":"jobsJobid","summary":"Job details","description":"One job listing by ID.\n\nReference: https://www.twittrapi.com/docs/reference/jobs-jobid","tags":["Jobs"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/jobs-jobid"},"parameters":[{"name":"jobId","in":"path","required":true,"description":"Numeric job ID.","schema":{"type":"string","pattern":"^[0-9]+$"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's JobScreenQuery.\n\nWith format=simple: {data: Job}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/JobResult"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"jobId is not numeric.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/jobs/find-location/{term}":{"get":{"operationId":"jobsFindLocationTerm","summary":"Find job location","description":"Location IDs for the jobLocationId filter of job search. Returns up to 10 matches.\n\nReference: https://www.twittrapi.com/docs/reference/jobs-find-location-term","tags":["Jobs"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/jobs-find-location-term"},"parameters":[{"name":"term","in":"path","required":true,"description":"Place name, URL-encoded.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's LocationSelectorQuery.\n\nWith format=simple: Collection of {id, name} location suggestions (no cursor).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/JobLocationPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/trends/{locationId}":{"get":{"operationId":"trendsLocationid","summary":"Trends by location","description":"Current trending topics for a place, by WOEID.\n\nReference: https://www.twittrapi.com/docs/reference/trends-locationid","tags":["Trends"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/trends-locationid"},"parameters":[{"name":"locationId","in":"path","required":true,"description":"Yahoo WOEID, digits only (1 to 12). 1 is worldwide, 23424977 the United States. /misc/locations lists them all.","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's v1.1 trends/place endpoint: an array with one object holding trends (name, url, query, tweet_volume), as_of and locations.\n\nWith format=simple: Collection of Trend objects {name, query, url, tweetVolume} (no cursor). query is URL-decoded.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TrendPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"locationId is missing or not a numeric WOEID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/misc/locations":{"get":{"operationId":"miscLocations","summary":"Trend locations","description":"All places X has trends for, with their WOEIDs.\n\nReference: https://www.twittrapi.com/docs/reference/misc-locations","tags":["Trends"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/misc-locations"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's v1.1 trends/available endpoint: an array of places with name, woeid, country and placeType.\n\nWith format=simple: Collection of TrendLocation objects {woeid, name, country, countryCode, placeType, parentId} (no cursor).","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TrendLocationPage"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/misc/emojis":{"get":{"operationId":"miscEmojis","summary":"Hashflags","description":"X's hashflags: hashtags that show a custom emoji, with image URLs and active dates.\n\nReference: https://www.twittrapi.com/docs/reference/misc-emojis","tags":["Misc"],"externalDocs":{"url":"https://www.twittrapi.com/docs/reference/misc-emojis"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"responses":{"200":{"description":"Raw JSON of X's v1.1 hashflags.json.\n\nWith format=simple: Unchanged inside {data: ...}: X's hashflag list is already small, so the simple format only adds the envelope.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}},"X-Response-Format":{"description":"simple when the simple format was returned","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/DataPassthrough"},{"$ref":"#/components/schemas/RawPassthrough"}],"description":"format=simple: the simple-format schema. Default (raw): X's JSON, passthrough."}}}},"400":{"description":"Any upstream failure (\"Error making emoji request.\"). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"}}}},"/client/create":{"post":{"operationId":"clientCreate","summary":"Post a tweet","description":"Post a tweet, quote tweet, long tweet, community tweet or scheduled tweet from your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-create","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-create"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"text":{"type":"string","description":"Tweet text. Over 280 characters it is sent as a long post (note tweet)."},"media_ids":{"type":"array","items":{"type":"string"},"description":"Media IDs from /client/media or /client/media/video."},"possibly_sensitive":{"type":"boolean","default":false,"description":"Mark the media as sensitive."},"conversation_control_mode":{"type":"string","description":"Who can reply: only_follows, only_verified or only_mentioned. Not used for community tweets."},"quote_url":{"type":"string","description":"URL of a tweet to quote."},"community_id":{"type":"string","description":"Post into this community."},"is_note_tweet":{"type":"boolean","default":false,"description":"Force a long post even for short text."},"schedule_time":{"type":"integer","description":"Unix time in seconds. When set, the tweet is scheduled instead of posted; only text and media are used."}},"required":["cookie","proxy","text"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","text":"Hello from the API"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: Tweet}: the tweet you just posted. With schedule_time: {data: {success: true, scheduledTweetId}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/reply":{"post":{"operationId":"clientReply","summary":"Reply to a tweet","description":"Reply to a tweet from your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-reply","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-reply"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"id":{"type":"string","description":"ID of the tweet to reply to."},"text":{"type":"string","description":"Reply text."},"media_ids":{"type":"array","items":{"type":"string"},"description":"Media IDs from /client/media."},"attachment_url":{"type":"string","description":"URL of a tweet to quote in the reply."},"possibly_sensitive":{"type":"boolean","default":false,"description":"Mark the media as sensitive."}},"required":["cookie","proxy","id","text"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","id":"20","text":"Nice"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: Tweet}: the reply you just posted. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/like":{"post":{"operationId":"clientLike","summary":"Like a tweet","description":"Like a tweet from your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-like","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-like"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to like."}},"required":["cookie","proxy","tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"20"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/retweet":{"post":{"operationId":"clientRetweet","summary":"Retweet","description":"Retweet a tweet from your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-retweet","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-retweet"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to retweet."}},"required":["cookie","proxy","tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"20"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true, retweetId}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/deleteTweet":{"post":{"operationId":"clientDeletetweet","summary":"Delete a tweet","description":"Delete one of your own tweets.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-deletetweet","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-deletetweet"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to delete."}},"required":["cookie","proxy","tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"1790000000000000000"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/follow":{"post":{"operationId":"clientFollow","summary":"Follow a user","description":"Follow an account from your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-follow","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-follow"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"user_id":{"type":"string","description":"Numeric ID of the account to follow. Either user_id or username is required."},"username":{"type":"string","description":"Handle of the account to follow. Used instead of user_id when set."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","username":"XDevelopers"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: User}: the account you followed, the same User object as the read endpoints. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON. Neither user_id nor username is set, or the user could not be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/bookmark":{"post":{"operationId":"clientBookmark","summary":"Bookmark a tweet","description":"Add a tweet to your bookmarks.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-bookmark","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-bookmark"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to bookmark."}},"required":["cookie","proxy","tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"20"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/unbookmark":{"post":{"operationId":"clientUnbookmark","summary":"Remove a bookmark","description":"Remove a tweet from your bookmarks.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-unbookmark","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-unbookmark"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to remove from your bookmarks."}},"required":["cookie","proxy","tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"20"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/bookmarks":{"post":{"operationId":"clientBookmarks","summary":"List bookmarks","description":"Tweets in your bookmarks.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-bookmarks","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-bookmarks"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"count":{"type":"integer","default":20,"description":"Tweets per page."},"cursor":{"type":"string","description":"Bottom cursor from the previous page."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","count":20}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/home-timeline":{"post":{"operationId":"clientHomeTimeline","summary":"Home timeline","description":"The home timeline of your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-home-timeline","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-home-timeline"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"count":{"type":"integer","default":20,"description":"Tweets to ask X for."},"include_promoted_content":{"type":"boolean","default":true,"description":"Include promoted tweets."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","count":20}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: Collection of Tweet objects: {data: [Tweet], nextCursor, previousCursor, hasNextPage}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/schedule-overview":{"post":{"operationId":"clientScheduleOverview","summary":"List scheduled tweets","description":"Tweets scheduled on your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-schedule-overview","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-schedule-overview"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"ascending":{"type":"boolean","default":true,"description":"Oldest first when true."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: Collection of scheduled tweets {id, text, executeAt, state, mediaIds}, without cursors (hasNextPage false). executeAt is RFC 3339. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/schedule-delete":{"post":{"operationId":"clientScheduleDelete","summary":"Delete a scheduled tweet","description":"Cancel a scheduled tweet.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-schedule-delete","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-schedule-delete"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"scheduled_tweet_id":{"type":"string","description":"ID from /client/schedule-overview."}},"required":["cookie","proxy","scheduled_tweet_id"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","scheduled_tweet_id":"1790000000000000000"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/media":{"post":{"operationId":"clientMedia","summary":"Upload an image","description":"Upload an image and get a media ID for /client/create or /client/reply.\n\nThe response field you need is media_id_string inside response.\n\nLimits (X): JPEG, PNG, WebP up to 5 MB; GIF up to 15 MB; at most 8192 x 8192 pixels. BMP, TIFF and other formats are refused. For videos use /client/media/video.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-media","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-media"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"media":{"type":"string","contentEncoding":"base64","description":"The image file, base64-encoded. JPEG, PNG or WebP up to 5 MB, GIF up to 15 MB; at most 8192 x 8192 pixels."},"media_type":{"type":"string","description":"MIME type, e.g. image/jpeg or image/png. Optional: the API detects the type from the file's bytes and uses the detected type if this is missing or wrong."}},"required":["cookie","proxy","media"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","media":"<base64>","media_type":"image/jpeg"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {mediaId, mediaKey, expiresAfterSecs}}. Pass mediaId in media_ids of /client/create or /client/reply. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON. The file breaks X's limits (not JPEG, PNG, GIF or WebP; over 5 MB, or 15 MB for a GIF; over 8192 x 8192 pixels; or a damaged image header). Checked before anything is sent to X, refunded. The error names the limit and the file's value, e.g. \"Banner must be between 200x100 and 8192x8192 pixels (got 120x60)\" or \"Profile photo must be at most 2 MB (got 3.4 MB)\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted. media is not valid base64.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/media/video":{"post":{"operationId":"clientMediaVideo","summary":"Upload a video","description":"Upload a video in 5 MB chunks, wait for X to process it, and get a media ID.\n\nRequest bodies are limited to 100 MB at the gateway (413 above that). With base64 overhead that is a video of about 75 MB.\n\nLimits (X): MP4 or MOV, up to 512 MB; up to 140 seconds without Premium, under 4 hours with Premium.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-media-video","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-media-video"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"media":{"type":"string","contentEncoding":"base64","description":"The video file, base64-encoded. MP4 or MOV, up to 512 MB (X's limit; the gateway's 100 MB body limit applies first)."},"media_type":{"type":"string","description":"MIME type, e.g. video/mp4 or video/quicktime. Optional: the API detects the type from the file's bytes and uses the detected type if this is missing or wrong."},"video_duration_ms":{"type":"integer","description":"Length of the video in milliseconds. Must be under 4 hours; X allows 140 seconds without Premium and refuses longer videos itself."}},"required":["cookie","proxy","media","video_duration_ms"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","media":"<base64>","media_type":"video/mp4","video_duration_ms":12000}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {mediaId, mediaKey, expiresAfterSecs}}. Pass mediaId in media_ids of /client/create or /client/reply. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON. The file breaks X's limits (not MP4 or MOV, over 512 MB, or video_duration_ms not positive or 4 hours or more). Checked before anything is sent to X, refunded. The error names the limit and the file's value, e.g. \"Banner must be between 200x100 and 8192x8192 pixels (got 120x60)\" or \"Profile photo must be at most 2 MB (got 3.4 MB)\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"408":{"description":"X did not finish processing in time. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted. media is not valid base64, or X reports that processing failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/profile":{"post":{"operationId":"clientProfile","summary":"Update your profile","description":"Change the name, bio, location, website or birth date of your account. Fields you leave out stay as they are.\n\nRuns the same request as the Edit profile dialog on x.com. Send at least one of the profile fields; an empty string clears description, location or url.\n\nOn a verified (Premium) account, x.com warns that changing the name can remove the checkmark until X has reviewed the change.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-profile","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-profile"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"name":{"type":"string","description":"Display name, up to 50 characters. Cannot be empty."},"description":{"type":"string","description":"Bio, up to 160 characters."},"location":{"type":"string","description":"Location, up to 30 characters."},"url":{"type":"string","description":"Website, up to 100 characters."},"birthdate":{"type":"string","description":"{day, month, year, visibility?, year_visibility?}. visibility and year_visibility are public, followers, following, mutualfollow or self; left out, X keeps the current setting. The date must be real, not in the future and at most 120 years back. null removes the birth date."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","description":"Building things with the API","location":"Berlin"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON. On success response is your updated user object (X's v1.1 user: name, description, location, url, profile_image_url_https, ...).\n\nWith format=simple: {data: User}: your profile after the change, the same User object as the read endpoints. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, or the cookie has no ct0. No profile field is set, a field is too long or not a string, name is empty, or birthdate is not a valid date or visibility. Also: the account is suspended, or X rejected the session.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"X refused the change: answered with X's status and {\"error\": \"X refused the profile update: <X's reason>\"}; when the image upload itself fails: \"X refused the image upload: <reason>\"."}}}},"/client/profile/image":{"post":{"operationId":"clientProfileImage","summary":"Change your profile picture","description":"Upload an image and set it as the profile picture of your account.\n\nThe image is uploaded like /client/media and then set as your avatar in one call. x.com crops the picture to a square in the browser before uploading; do the same if you want a specific part shown.\n\nLimits (X): JPEG, PNG or GIF, up to 2 MB, at most 8192 x 8192 pixels. X does not animate GIFs in profile pictures.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-profile-image","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-profile-image"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"media":{"type":"string","contentEncoding":"base64","description":"The image file, base64-encoded. JPEG, PNG or GIF, up to 2 MB, at most 8192 x 8192 pixels (400 x 400 recommended)."},"media_type":{"type":"string","description":"MIME type, e.g. image/jpeg or image/png. Optional: the API detects the type from the file's bytes and uses the detected type if this is missing or wrong."}},"required":["cookie","proxy","media"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","media":"<base64>","media_type":"image/jpeg"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON. On success response is your updated user object; the new picture is in profile_image_url_https.\n\nWith format=simple: {data: User}: your profile with the new avatarUrl, the same User object as the read endpoints. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON. The file breaks X's limits (not JPEG, PNG or GIF; over 2 MB; over 8192 x 8192 pixels; or a damaged image header). Checked before anything is sent to X, refunded. The error names the limit and the file's value, e.g. \"Banner must be between 200x100 and 8192x8192 pixels (got 120x60)\" or \"Profile photo must be at most 2 MB (got 3.4 MB)\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, or the cookie has no ct0. media is missing, not valid base64, or empty. Also: the account is suspended, or X rejected the session.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"X refused the change: answered with X's status and {\"error\": \"X refused the profile update: <X's reason>\"}; when the image upload itself fails: \"X refused the image upload: <reason>\"."}}}},"/client/profile/banner":{"post":{"operationId":"clientProfileBanner","summary":"Change your header image","description":"Upload an image and set it as the header (banner) of your account.\n\nThe image is uploaded like /client/media and then set as your banner in one call. X shows headers at 3:1 (1500 x 500 recommended); x.com crops in the browser before uploading, so crop the image yourself first.\n\nLimits (X): JPEG, PNG or GIF, up to 5 MB, between 200 x 100 and 8192 x 8192 pixels. X does not animate GIFs in headers.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-profile-banner","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-profile-banner"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"media":{"type":"string","contentEncoding":"base64","description":"The image file, base64-encoded. JPEG, PNG or GIF, up to 5 MB, between 200 x 100 and 8192 x 8192 pixels (1500 x 500 recommended)."},"media_type":{"type":"string","description":"MIME type, e.g. image/jpeg or image/png. Optional: the API detects the type from the file's bytes and uses the detected type if this is missing or wrong."}},"required":["cookie","proxy","media"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","media":"<base64>","media_type":"image/jpeg"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON. On success response is your updated user object; the new header is in profile_banner_url.\n\nWith format=simple: {data: User}: your profile with the new bannerUrl, the same User object as the read endpoints. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON. The file breaks X's limits (not JPEG, PNG or GIF; over 5 MB; smaller than 200 x 100 or larger than 8192 x 8192 pixels; or a damaged image header). Checked before anything is sent to X, refunded. The error names the limit and the file's value, e.g. \"Banner must be between 200x100 and 8192x8192 pixels (got 120x60)\" or \"Profile photo must be at most 2 MB (got 3.4 MB)\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, or the cookie has no ct0. media is missing, not valid base64, or empty. Also: the account is suspended, or X rejected the session.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"X refused the change: answered with X's status and {\"error\": \"X refused the profile update: <X's reason>\"}; when the image upload itself fails: \"X refused the image upload: <reason>\"."}}}},"/client/report":{"post":{"operationId":"clientReport","summary":"Report a tweet","description":"Report a tweet and its author to X.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-report","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-report"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"tweet_id":{"type":"string","description":"ID of the tweet to report."},"user_id":{"type":"string","description":"Numeric ID of the tweet's author."},"reason":{"type":"string","description":"One of SpamSimpleOption, HateOrAbuseSimpleOption, ChildSafetySimpleOption, ViolentSpeechSimpleOption, ViolentMediaSimpleOption, IRBSimpleOption, ImpersonationSimpleOption, AdultContentSimpleOption, PrivateContentSimpleOption, SuicideSelfHarmSimpleOption, TerrorismSimpleOption, CivicIntegritySimpleOption."}},"required":["cookie","proxy","tweet_id","user_id","reason"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","tweet_id":"1790000000000000000","user_id":"12","reason":"SpamSimpleOption"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/client/communities/create":{"post":{"operationId":"clientCommunitiesCreate","summary":"Create a community","description":"Create an X Community owned by your account.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-communities-create","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-communities-create"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"name":{"type":"string","description":"Community name."},"description":{"type":"string","description":"Community description."},"joinPolicy":{"type":"string","default":"Open","description":"Passed to X as is."},"invitesPolicy":{"type":"string","default":"MemberInvitesAllowed","description":"Passed to X as is."},"question":{"type":"string","description":"Question for people who ask to join."}},"required":["cookie","proxy","name"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","name":"API testers"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: Community}: the community you created. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"cookie, proxy or name is missing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"description":"The session could not be prepared (for example the cookie has no ct0, or the proxy is unreachable). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"Any status X answers with: passed through with X's body."}}}},"/client/communities/remove":{"post":{"operationId":"clientCommunitiesRemove","summary":"Delete a community","description":"Delete a community your account owns.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-communities-remove","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-communities-remove"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"community_id":{"type":"string","description":"Community ID."},"name":{"type":"string","description":"Community name. Sent to X together with the ID."}},"required":["cookie","proxy","community_id","name"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port","community_id":"1500000000000000000","name":"API testers"}}}},"responses":{"200":{"description":"Wrapper built by the API: {\"status_code\": <X status>, \"response\": \"<X response body as a string>\"}. The HTTP status is X's status when X answered 4xx or 5xx, otherwise 200. Parse response a second time to get X's JSON.\n\nWith format=simple: {data: {success: true}}. When X reports an error inside the wrapper (for example a tweet that is already liked), the usual wrapper is returned unchanged.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"A required field is missing (including proxy), an ID is not numeric, or the cookie has no ct0. Also: the account is suspended, X rejected the session, or the text was already posted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"Any status X answers with (for example 401, 403, 404): passed through with X's body."}}}},"/premium/analyticsOverview":{"post":{"operationId":"premiumAnalyticsoverview","summary":"Account analytics overview","description":"The account analytics overview of your X account (needs X Premium).\n\nReference: https://www.twittrapi.com/docs/account-actions/premium-analyticsoverview","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/premium-analyticsoverview"},"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token and ct0; guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...","proxy":"http://user:pass@host:port"}}}},"responses":{"200":{"description":"X's AccountOverviewQuery response, passed through with X's status code and content type. Not wrapped in {status_code, response}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"cookie is missing, the body is not valid JSON, the cookie has no ct0, or the proxy URL is invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"description":"proxy is missing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/ServerError"},"502":{"description":"The request to X failed (for example through the proxy). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"Any status X answers with: passed through."}}}},"/client/dm/inbox":{"post":{"operationId":"clientDmInbox","summary":"List conversations","description":"Your DM inbox: conversations with participants and settings, and with the passcode their latest messages.\n\nWithout a passcode you get the conversations, their participants and settings, but no message text. With the passcode each conversation also carries its latest messages, decrypted.\n\n501 and the passcode errors only occur when a passcode is sent.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-inbox","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-inbox"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"passcode":{"type":"string","description":"Your X Chat passcode, the one you set up for encrypted messages on X. Without it the conversations are listed without messages. Send it as a string (a number works too, but loses leading zeros), up to 64 characters. It unlocks your chat keys for this request and is not saved. The unlocked keys stay in the server's memory for up to 30 minutes, so follow-up calls need no new unlock."},"count":{"type":"integer","default":20,"description":"Conversations to return, 1 to 50."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","passcode":"1234","count":20}}}},"responses":{"200":{"description":"{conversations: [...], message_requests_count, decrypted}. decrypted is true when a passcode was sent. Each conversation: {conversation_id, type (direct or group), name (groups), muted, disappearing_messages {enabled, ttl_seconds}, screen_capture_blocking, participants [{id, screen_name, name, avatar, is_blue_verified}], detail (X's conversation_detail)}, messages (with passcode: the latest ones, newest first), undecrypted (events that could not be read: {id, sender_id, error}), decrypt_error (when the conversation could not be decrypted) and events (other decrypted events such as read receipts and key changes). Each message: id (sequence ID, also the cursor unit), message_id, conversation_id, sender_id, created_at and expires_at (Unix milliseconds; expires_at only in chats with disappearing messages), type (text, reaction, reaction_removed, edit, deleted, ...), text, verified (the sender's signature was checked) and content (the decrypted message as X's chat library returns it: reactions, replies, attachments). Expired disappearing messages are left out.\n\nWith format=simple: Collection of conversations without cursors: {data: [id, type (direct or group), name, muted, disappearingMessages {enabled, ttlSeconds}, screenCaptureBlocking, participants [{id, username, name, avatarUrl, verified}], lastMessage, messages]}. Message objects {id, senderId, createdAt, expiresAt, type, text, emoji, targetId, replyTo {id, senderId, text}, attachments [{kind, type, filename, filesizeBytes, durationMs, width, height, url, mediaHashKey}], verified}; times are RFC 3339, unknown values null. Without a passcode lastMessage is null and messages is [].","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. count is not a number from 1 to 50. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\"). Wrong passcode: \"Wrong passcode (N attempts left before X deletes the chat keys)\". X deletes the chat keys after too many wrong passcodes, so the API never sends the same wrong passcode to X twice (for 24 hours it answers 422 at once), and once only 3 attempts are left it does not try at all: \"Only a few passcode attempts are left for this account; unlock Chat in the X app with the correct passcode first\". The account has no chat passcode yet: open Chat on x.com once and set one up.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"501":{"description":"Encrypted messages are not available on this server (the passcode cannot be used). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"The chat keys could not be unlocked (\"Could not unlock the chat keys, try again\") or the messages could not be decrypted. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/conversation":{"post":{"operationId":"clientDmConversation","summary":"Read a conversation","description":"Messages of one conversation, decrypted, newest first, with a cursor for older messages.\n\nPaginated: pass the bottom cursor of one page as cursor to get the next. Each page is one billed call.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-conversation","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-conversation"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"passcode":{"type":"string","description":"Your X Chat passcode, the one you set up for encrypted messages on X. Send it as a string (a number works too, but loses leading zeros), up to 64 characters. It unlocks your chat keys for this request and is not saved. The unlocked keys stay in the server's memory for up to 30 minutes, so follow-up calls need no new unlock."},"conversation_id":{"type":"string","description":"ID of the conversation, as returned by /client/dm/inbox. A one-to-one chat has the ID <smaller user ID>:<larger user ID>. Letters, digits, colon, hyphen and underscore, up to 128 characters. Either conversation_id or user_id is required."},"user_id":{"type":"string","description":"Numeric ID of the other person (up to 20 digits) for a one-to-one chat. Used when conversation_id is not set."},"cursor":{"type":"string","description":"cursor from the previous page (digits only, up to 20) to get older messages. Leave it out for the newest page."}},"required":["cookie","proxy","passcode"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","passcode":"1234","user_id":"12"}}}},"responses":{"200":{"description":"{conversation_id, messages, has_more, cursor, message_request_state, undecrypted, events}. messages are newest first; cursor is set when has_more is true. undecrypted lists events the API could not read ({id, sender_id, error}; for example data x.com keeps in your own conversation), events the other decrypted events (read receipts, settings and key changes). Each message: id (sequence ID, also the cursor unit), message_id, conversation_id, sender_id, created_at and expires_at (Unix milliseconds; expires_at only in chats with disappearing messages), type (text, reaction, reaction_removed, edit, deleted, ...), text, verified (the sender's signature was checked) and content (the decrypted message as X's chat library returns it: reactions, replies, attachments). Expired disappearing messages are left out.\n\nWith format=simple: Collection of Message objects {id, senderId, createdAt, expiresAt, type, text, emoji, targetId, replyTo {id, senderId, text}, attachments [{kind, type, filename, filesizeBytes, durationMs, width, height, url, mediaHashKey}], verified}; times are RFC 3339, unknown values null. nextCursor is the cursor for older messages, null on the last page.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. The passcode is missing, neither conversation_id nor user_id is set, user_id is not numeric, conversation_id or cursor has the wrong format. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\"). Wrong passcode: \"Wrong passcode (N attempts left before X deletes the chat keys)\". X deletes the chat keys after too many wrong passcodes, so the API never sends the same wrong passcode to X twice (for 24 hours it answers 422 at once), and once only 3 attempts are left it does not try at all: \"Only a few passcode attempts are left for this account; unlock Chat in the X app with the correct passcode first\". The account has no chat passcode yet: open Chat on x.com once and set one up.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"501":{"description":"Encrypted messages are not available on this server (the passcode cannot be used). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"The chat keys could not be unlocked (\"Could not unlock the chat keys, try again\") or the messages could not be decrypted. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/conversation/info":{"post":{"operationId":"clientDmConversationInfo","summary":"Conversation details","description":"Participants and settings of one conversation: disappearing messages, screen capture blocking, muted. No passcode needed.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-conversation-info","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-conversation-info"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"conversation_id":{"type":"string","description":"ID of the conversation, as returned by /client/dm/inbox. A one-to-one chat has the ID <smaller user ID>:<larger user ID>. Letters, digits, colon, hyphen and underscore, up to 128 characters. Either conversation_id or user_id is required."},"user_id":{"type":"string","description":"Numeric ID of the other person (up to 20 digits) for a one-to-one chat. Used when conversation_id is not set."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","user_id":"12"}}}},"responses":{"200":{"description":"{conversation_id, type (direct or group), name (groups), muted, disappearing_messages {enabled, ttl_seconds}, screen_capture_blocking, participants [{id, screen_name, name, avatar, is_blue_verified}], detail (X's conversation_detail)}. ttl_seconds is set when disappearing messages are on.\n\nWith format=simple: {data: {id, type (direct or group), name, muted, disappearingMessages {enabled, ttlSeconds}, screenCaptureBlocking, participants [{id, username, name, avatarUrl, verified}]}}. ttlSeconds is null when disappearing messages are off.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"Conversation not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. Neither conversation_id nor user_id is set, user_id is not numeric, or conversation_id has the wrong format. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\").","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/conversation/disappearing":{"post":{"operationId":"clientDmConversationDisappearing","summary":"Disappearing messages","description":"Turn disappearing messages of a conversation on, change the time, or turn them off.\n\nNew messages in the conversation are deleted ttl_seconds after they were sent. Like x.com, the change is signed with your chat key, so the passcode is required. The API reads the setting back and answers with the conversation as it is afterwards; when the conversation already has the requested setting, nothing is changed.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-conversation-disappearing","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-conversation-disappearing"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"passcode":{"type":"string","description":"Your X Chat passcode, the one you set up for encrypted messages on X. Send it as a string (a number works too, but loses leading zeros), up to 64 characters. It unlocks your chat keys for this request and is not saved. The unlocked keys stay in the server's memory for up to 30 minutes, so follow-up calls need no new unlock."},"conversation_id":{"type":"string","description":"ID of the conversation, as returned by /client/dm/inbox. A one-to-one chat has the ID <smaller user ID>:<larger user ID>. Letters, digits, colon, hyphen and underscore, up to 128 characters. Either conversation_id or user_id is required."},"user_id":{"type":"string","description":"Numeric ID of the other person (up to 20 digits) for a one-to-one chat. Used when conversation_id is not set."},"ttl_seconds":{"type":"integer","description":"0 turns disappearing messages off; otherwise 60 (1 minute) to 31536000 (365 days)."}},"required":["cookie","proxy","passcode","ttl_seconds"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","passcode":"1234","user_id":"12","ttl_seconds":86400}}}},"responses":{"200":{"description":"The conversation after the change, like /client/dm/conversation/info: {conversation_id, type (direct or group), name (groups), muted, disappearing_messages {enabled, ttl_seconds}, screen_capture_blocking, participants [{id, screen_name, name, avatar, is_blue_verified}], detail (X's conversation_detail)}.\n\nWith format=simple: {data: {id, type (direct or group), name, muted, disappearingMessages {enabled, ttlSeconds}, screenCaptureBlocking, participants [{id, username, name, avatarUrl, verified}]}}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"description":"Conversation not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. The passcode or ttl_seconds is missing, ttl_seconds is not 0 or between 60 and 31536000, or the conversation is not set. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\"). Wrong passcode: \"Wrong passcode (N attempts left before X deletes the chat keys)\". X deletes the chat keys after too many wrong passcodes, so the API never sends the same wrong passcode to X twice (for 24 hours it answers 422 at once), and once only 3 attempts are left it does not try at all: \"Only a few passcode attempts are left for this account; unlock Chat in the X app with the correct passcode first\". The account has no chat passcode yet: open Chat on x.com once and set one up.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"501":{"description":"Encrypted messages are not available on this server (the passcode cannot be used). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"The chat keys could not be unlocked (\"Could not unlock the chat keys, try again\") or the messages could not be decrypted. Refunded. X accepted the change but the setting did not change (\"X accepted the change but did not apply it\"), or the change could not be signed. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/send":{"post":{"operationId":"clientDmSend","summary":"Send a message","description":"Send an encrypted text message to a conversation or to a user.\n\nThe message is encrypted and signed with your chat key, like on x.com. The first message to a person you have not written to yet starts the encrypted conversation; that person needs X Chat (encrypted messages) on their account. Text only, no media.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-send","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-send"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"passcode":{"type":"string","description":"Your X Chat passcode, the one you set up for encrypted messages on X. Send it as a string (a number works too, but loses leading zeros), up to 64 characters. It unlocks your chat keys for this request and is not saved. The unlocked keys stay in the server's memory for up to 30 minutes, so follow-up calls need no new unlock."},"conversation_id":{"type":"string","description":"ID of the conversation, as returned by /client/dm/inbox. A one-to-one chat has the ID <smaller user ID>:<larger user ID>. Letters, digits, colon, hyphen and underscore, up to 128 characters. Either conversation_id or user_id is required."},"user_id":{"type":"string","description":"Numeric ID of the other person (up to 20 digits) for a one-to-one chat. Used when conversation_id is not set."},"text":{"type":"string","description":"Message text, up to 10,000 characters. Must not be empty or only spaces."}},"required":["cookie","proxy","passcode","text"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","passcode":"1234","user_id":"12","text":"Hello"}}}},"responses":{"200":{"description":"{conversation_id, id (sequence ID), message_id, created_at (Unix milliseconds), text}.\n\nWith format=simple: {data: {id, messageId, conversationId, createdAt, text}}. createdAt is RFC 3339.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. The passcode or text is missing, text is longer than 10,000 characters, neither conversation_id nor user_id is set, or one of them has the wrong format. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\"). The recipient cannot receive encrypted messages (no X Chat key), or the conversation has no key you can use (for example a group you cannot write to). Wrong passcode: \"Wrong passcode (N attempts left before X deletes the chat keys)\". X deletes the chat keys after too many wrong passcodes, so the API never sends the same wrong passcode to X twice (for 24 hours it answers 422 at once), and once only 3 attempts are left it does not try at all: \"Only a few passcode attempts are left for this account; unlock Chat in the X app with the correct passcode first\". The account has no chat passcode yet: open Chat on x.com once and set one up.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"501":{"description":"Encrypted messages are not available on this server (the passcode cannot be used). Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"The chat keys could not be unlocked (\"Could not unlock the chat keys, try again\") or the messages could not be decrypted. Refunded. The message or a new conversation key could not be encrypted. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/settings":{"post":{"operationId":"clientDmSettings","summary":"DM settings","description":"Who can message you, read receipts, the message quality filter and audio/video call settings. No passcode needed.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-settings","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-settings"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port"}}}},"responses":{"200":{"description":"{allow_dms_from, dm_receipt_settings, dm_quality_filter, av_settings: {has_av_calls_enabled, av_call_permissions: {accept_calls_from_everyone, accept_calls_from_following, accept_calls_from_verified, accept_calls_from_addressbook}}}. Values as X sends them; dm_receipt_settings and dm_quality_filter are left out when X does not send them.\n\nWith format=simple: {data: {allowDmsFrom, readReceipts, qualityFilter, calls: {enabled, fromEveryone, fromFollowing, fromVerified, fromAddressBook}}}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters.  Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\").","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"502":{"description":"X returned no DM settings. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/client/dm/settings/update":{"post":{"operationId":"clientDmSettingsUpdate","summary":"Change DM settings","description":"Change who can message you, read receipts and call settings. Settings you leave out stay as they are.\n\nThe API reads your current settings, applies the fields you send and saves the full set, like x.com does. Send at least one setting. No passcode needed.\n\nReference: https://www.twittrapi.com/docs/account-actions/client-dm-settings-update","tags":["Account actions"],"externalDocs":{"url":"https://www.twittrapi.com/docs/account-actions/client-dm-settings-update"},"parameters":[{"name":"format","in":"query","required":false,"description":"raw (default): X's JSON passed through. simple: flat camelCase JSON with a fixed schema and a {data, nextCursor, previousCursor, hasNextPage} envelope. Same price. The header X-Response-Format: simple does the same.","schema":{"type":"string","enum":["raw","simple"],"default":"raw"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cookie":{"type":"string","description":"Cookie header of your own logged-in X session. Must contain auth_token, ct0 and twid (your account ID, set by x.com at login); guest_id is used when present."},"proxy":{"type":"string","description":"Your proxy, format http://user:pass@host:port. The requests to X go out through it. Used only for this request."},"allow_dms_from":{"type":"string","description":"Who can send you messages, X's value such as all or verified (/client/dm/settings shows your current one). Lower-case letters and underscore, up to 64 characters; X decides which values it accepts."},"dm_receipt_settings":{"type":"string","description":"Read receipts, X's value (same format as allow_dms_from)."},"always_allow_dms_from_subscribers":{"type":"boolean","description":"Always accept messages from your subscribers."},"av_calls_enabled":{"type":"boolean","description":"Allow audio and video calls."},"accept_calls_from_everyone":{"type":"boolean","description":"Accept calls from everyone."},"accept_calls_from_following":{"type":"boolean","description":"Accept calls from people you follow."},"accept_calls_from_verified":{"type":"boolean","description":"Accept calls from verified users."},"accept_calls_from_addressbook":{"type":"boolean","description":"Accept calls from your contacts."}},"required":["cookie","proxy"]},"example":{"cookie":"auth_token=...; ct0=...; twid=u%3D...","proxy":"http://user:pass@host:port","allow_dms_from":"verified","av_calls_enabled":false}}}},"responses":{"200":{"description":"Your DM settings after the change, like /client/dm/settings.\n\nWith format=simple: {data: {allowDmsFrom, readReceipts, qualityFilter, calls: {enabled, fromEveryone, fromFollowing, fromVerified, fromAddressBook}}}.","headers":{"X-Price-Per-Call":{"description":"What this call cost, in USD","schema":{"type":"string"}},"X-Remaining-Balance":{"description":"Balance after this call (and after a refund, if any)","schema":{"type":"string"}},"X-Refunded":{"description":"true when the call was refunded","schema":{"type":"string"}},"X-Retried":{"description":"true when the gateway needed more than one attempt","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RawPassthrough"}}}},"400":{"description":"The body is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"402":{"$ref":"#/components/responses/PaymentRequired"},"403":{"$ref":"#/components/responses/Forbidden"},"407":{"description":"The proxy is unreachable or timed out.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"cookie or proxy is missing, the cookie has no twid or ct0, or the passcode is neither a string nor a whole number or longer than 64 characters. No setting is sent, a string setting is empty, too long or has other characters than lower-case letters and underscore, or a boolean setting is not true or false. Also: the account is suspended, or X rejected the session (\"Twitter temporarily rejected this session; refresh the login and try again\").","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"X's rate limit for this account: \"X rate limit reached for this account, try again later\".","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"$ref":"#/components/responses/ServerError"},"502":{"description":"X returned no DM settings. Refunded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"default":{"description":"X refused the request: answered with X's status and {\"error\": \"X refused the request: <X's reason>\"}. When X answers 200 with an error, the status is 422."}}}},"/balance":{"get":{"operationId":"getBalance","summary":"Balance of your key","description":"Current balance of the key. Free; its own limit of 10 requests per second. More fields exist that the dashboard uses. Reference: https://www.twittrapi.com/docs/billing","tags":["Account"],"externalDocs":{"url":"https://www.twittrapi.com/docs/billing"},"responses":{"200":{"description":"Balance","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"properties":{"user_id":{"type":"integer"},"balance":{"type":"number","description":"USD"},"price_per_call":{"type":"number","description":"USD"},"is_active":{"type":"boolean"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"description":"Unknown key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-KEY","description":"API key from the dashboard (https://app.twittrapi.com/register)."}},"schemas":{"Media":{"type":"object","properties":{"type":{"type":"string","enum":["photo","video","gif"]},"url":{"type":"string","description":"Photos: the image. Videos and GIFs: the MP4 with the highest bitrate."},"previewUrl":{"type":"string","description":"The image (poster frame for videos)"},"width":{"type":"integer"},"height":{"type":"integer"},"altText":{"type":["string","null"]},"durationMs":{"type":["integer","null"],"description":"Videos only"}},"required":["type","url","previewUrl","width","height","altText","durationMs"]},"User":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string","description":"Handle without @"},"name":{"type":"string","description":"Display name"},"description":{"type":"string","description":"Bio, t.co links expanded"},"location":{"type":"string"},"url":{"type":["string","null"],"description":"Website, expanded"},"createdAt":{"type":["string","null"],"format":"date-time"},"avatarUrl":{"type":["string","null"]},"bannerUrl":{"type":["string","null"]},"verified":{"type":"boolean","description":"Blue check"},"verifiedType":{"type":["string","null"],"description":"e.g. Business or Government"},"protected":{"type":"boolean","description":"Private account"},"counts":{"type":"object","properties":{"followers":{"type":"integer"},"following":{"type":"integer"},"tweets":{"type":"integer"},"likes":{"type":"integer"},"media":{"type":"integer"},"listed":{"type":"integer"}},"required":["followers","following","tweets","likes","media","listed"]},"pinnedTweetIds":{"type":"array","items":{"type":"string"}},"isAutomated":{"type":"boolean"}},"required":["id","username","name","description","location","url","createdAt","avatarUrl","bannerUrl","verified","verifiedType","protected","counts","pinnedTweetIds","isAutomated"]},"UserWithAbout":{"allOf":[{"$ref":"#/components/schemas/User"},{"type":"object","properties":{"about":{"type":"object","description":"accountBasedIn, locationAccurate, createdCountryAccurate, source, usernameChanges, lastUsernameChangeAt, affiliateUsername, identityVerified, verifiedSince","additionalProperties":true}},"required":["about"]}]},"UnavailableTweet":{"type":"object","properties":{"id":{"type":"string"},"unavailable":{"type":"boolean","const":true}},"required":["id","unavailable"],"description":"A tweet X did not return (deleted, suspended author, withheld)."},"Article":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"previewText":{"type":["string","null"]},"coverImageUrl":{"type":["string","null"]},"publishedAt":{"type":["string","null"]},"text":{"type":["string","null"]}},"required":["id","title","previewText","coverImageUrl","publishedAt","text"]},"Tweet":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string","description":"https://x.com/<username>/status/<id>"},"text":{"type":"string","description":"Full text, t.co links replaced by their targets"},"createdAt":{"type":["string","null"],"format":"date-time"},"lang":{"type":["string","null"]},"author":{"anyOf":[{"$ref":"#/components/schemas/User"},{"type":"null"}]},"counts":{"type":"object","properties":{"likes":{"type":"integer"},"retweets":{"type":"integer"},"replies":{"type":"integer"},"quotes":{"type":"integer"},"bookmarks":{"type":"integer"},"views":{"type":["integer","null"]}},"required":["likes","retweets","replies","quotes","bookmarks","views"]},"media":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"urls":{"type":"array","items":{"type":"string"}},"hashtags":{"type":"array","items":{"type":"string"}},"mentions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]}},"replyTo":{"anyOf":[{"type":"object","properties":{"tweetId":{"type":"string"},"userId":{"type":"string"},"username":{"type":"string"}},"required":["tweetId","userId","username"]},{"type":"null"}]},"quoted":{"anyOf":[{"$ref":"#/components/schemas/Tweet"},{"$ref":"#/components/schemas/UnavailableTweet"},{"type":"null"}]},"retweetOf":{"anyOf":[{"$ref":"#/components/schemas/Tweet"},{"type":"null"}]},"conversationId":{"type":["string","null"]},"isPinned":{"type":"boolean"},"source":{"type":["string","null"]},"article":{"anyOf":[{"$ref":"#/components/schemas/Article"},{"type":"null"}]}},"required":["id","url","text","createdAt","lang","author","counts","media","urls","hashtags","mentions","replyTo","quoted","retweetOf","conversationId","isPinned","source","article"]},"List":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"createdAt":{"type":["string","null"]},"memberCount":{"type":"integer"},"followerCount":{"type":"integer"},"private":{"type":"boolean"},"bannerUrl":{"type":["string","null"]},"owner":{"anyOf":[{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]},{"type":"null"}]}},"required":["id","name","description","createdAt","memberCount","followerCount","private","bannerUrl","owner"]},"Community":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","description":"Empty in search results"},"createdAt":{"type":["string","null"]},"memberCount":{"type":"integer"},"moderatorCount":{"type":"integer"},"joinPolicy":{"type":["string","null"]},"nsfw":{"type":"boolean"},"topic":{"type":["string","null"]},"bannerUrl":{"type":["string","null"]},"creator":{"anyOf":[{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]},{"type":"null"}]},"rules":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"}},"required":["id","name","description"]}}},"required":["id","name","description","createdAt","memberCount","moderatorCount","joinPolicy","nsfw","topic","bannerUrl","creator","rules"]},"Job":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"location":{"type":["string","null"]},"url":{"type":["string","null"],"description":"The employer's application page"},"description":{"type":["string","null"]},"company":{"anyOf":[{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"logoUrl":{"type":["string","null"]}},"required":["id","name","logoUrl"]},{"type":"null"}]},"postedBy":{"anyOf":[{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]},{"type":"null"}]}},"required":["id","title","location","url","description","company","postedBy"]},"JobLocation":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"Trend":{"type":"object","properties":{"name":{"type":"string"},"query":{"type":"string","description":"URL-decoded"},"url":{"type":"string"},"tweetVolume":{"type":["integer","null"]}},"required":["name","query","url","tweetVolume"]},"TrendLocation":{"type":"object","properties":{"woeid":{"type":"integer"},"name":{"type":"string"},"country":{"type":"string"},"countryCode":{"type":["string","null"]},"placeType":{"type":"string"},"parentId":{"type":["integer","null"]}},"required":["woeid","name","country","countryCode","placeType","parentId"]},"Friendship":{"type":"object","properties":{"source":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]},"target":{"type":"object","properties":{"id":{"type":"string"},"username":{"type":"string"}},"required":["id","username"]},"following":{"type":"boolean","description":"source follows target"},"followedBy":{"type":"boolean"},"canDm":{"type":"boolean"},"blocking":{"type":"boolean"},"blockedBy":{"type":"boolean"},"muting":{"type":"boolean"}},"required":["source","target","following","followedBy","canDm","blocking","blockedBy","muting"]},"RawPassthrough":{"type":"object","additionalProperties":true,"description":"X's own JSON (raw format, the default), passed through unchanged. The shape is X's and can change; see https://www.twittrapi.com/docs/response-format."},"Error":{"type":"object","properties":{"error":{"type":"string","description":"Message. Do not parse it; use the status code."},"errorInfo":{"description":"X's raw reply, on some endpoints"},"attempts":{"type":"integer","description":"Search retries"},"errorCode":{"type":"string"}},"required":["error"]},"TweetPage":{"type":"object","description":"Simple format: a page of tweets","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Tweet"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"UserPage":{"type":"object","description":"Simple format: a page of users","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/User"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"CommunityPage":{"type":"object","description":"Simple format: a page of communities","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Community"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"JobPage":{"type":"object","description":"Simple format: a page of jobs","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Job"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"JobLocationPage":{"type":"object","description":"Simple format: location suggestions (no cursor)","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/JobLocation"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"TrendPage":{"type":"object","description":"Simple format: trends (no cursor)","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Trend"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"TrendLocationPage":{"type":"object","description":"Simple format: trend locations (no cursor)","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TrendLocation"}},"nextCursor":{"type":["string","null"],"description":"Pass as cursor for the next page; null on the last page"},"previousCursor":{"type":["string","null"],"description":"X's top cursor, for polling newer items"},"hasNextPage":{"type":"boolean"}},"required":["data","nextCursor","previousCursor","hasNextPage"]},"TweetResult":{"type":"object","properties":{"data":{"anyOf":[{"$ref":"#/components/schemas/Tweet"},{"$ref":"#/components/schemas/UnavailableTweet"}]}},"required":["data"],"description":"Simple format: one tweet"},"UserResult":{"type":"object","properties":{"data":{"anyOf":[{"$ref":"#/components/schemas/User"},{"type":"null"}]}},"required":["data"],"description":"Simple format: one user (null when the handle does not exist)"},"UserAboutResult":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/UserWithAbout"}},"required":["data"],"description":"Simple format: one user with about"},"FriendshipResult":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Friendship"}},"required":["data"],"description":"Simple format: relationship of two accounts"},"CommunityResult":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Community"}},"required":["data"],"description":"Simple format: one community"},"ListResult":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/List"}},"required":["data"],"description":"Simple format: one list"},"JobResult":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Job"}},"required":["data"],"description":"Simple format: one job"},"DataPassthrough":{"type":"object","properties":{"data":{"type":["object","array"],"description":"The usual response, unchanged"}},"required":["data"],"description":"Simple format: the usual (already small) response inside {data: ...}"}},"responses":{"Unauthorized":{"description":"Missing or unknown API key. Not charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"PaymentRequired":{"description":"No balance left, or the trial expired. Not charged. Top up in the dashboard.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"Forbidden":{"description":"Key deactivated, or the endpoint is not in your plan (trial keys and account actions). Not charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"RateLimited":{"description":"Rate limit for your key exceeded. Not charged. No Retry-After header: back off exponentially.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"ServerError":{"description":"Something failed on our side or between us and X. Refunded (400, 408, 409 or a 5xx error are refunded). Retry with backoff.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}