From 6e9897701f7ac84df743d151eb4e8536041361c3 Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Wed, 19 Jun 2024 10:53:39 +0530 Subject: [PATCH 01/10] Generate Client via openApi --- ballerina/client.bal | 690 +- ballerina/types.bal | 3154 ++++++ ballerina/utils.bal | 201 + docs/twitter_open_api_spec.json | 15432 ++++++++++++++++++++++++++++++ 4 files changed, 19462 insertions(+), 15 deletions(-) create mode 100644 ballerina/types.bal create mode 100644 ballerina/utils.bal create mode 100644 docs/twitter_open_api_spec.json diff --git a/ballerina/client.bal b/ballerina/client.bal index 66cdc3f..93c8c77 100644 --- a/ballerina/client.bal +++ b/ballerina/client.bal @@ -1,15 +1,675 @@ -// Copyright (c) 2024, WSO2 LLC. (http://www.wso2.com). -// -// WSO2 LLC. licenses this file to you under the Apache License, -// Version 2.0 (the "License"); you may not use this file except -// in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. +// AUTO-GENERATED FILE. DO NOT MODIFY. +// This file is auto-generated by the Ballerina OpenAPI tool. + +import ballerina/http; + +# Twitter API v2 available endpoints +public isolated client class Client { + final http:Client clientEp; + # Gets invoked to initialize the `connector`. + # + # + config - The configurations to be used when initializing the `connector` + # + serviceUrl - URL of the target service + # + return - An error if connector initialization failed + public isolated function init(ConnectionConfig config, string serviceUrl = "https://api.twitter.com") returns error? { + http:ClientConfiguration httpClientConfig = {auth: config.auth, httpVersion: config.httpVersion, timeout: config.timeout, forwarded: config.forwarded, poolConfig: config.poolConfig, compression: config.compression, circuitBreaker: config.circuitBreaker, retryConfig: config.retryConfig, validation: config.validation}; + do { + if config.http1Settings is ClientHttp1Settings { + ClientHttp1Settings settings = check config.http1Settings.ensureType(ClientHttp1Settings); + httpClientConfig.http1Settings = {...settings}; + } + if config.http2Settings is http:ClientHttp2Settings { + httpClientConfig.http2Settings = check config.http2Settings.ensureType(http:ClientHttp2Settings); + } + if config.cache is http:CacheConfig { + httpClientConfig.cache = check config.cache.ensureType(http:CacheConfig); + } + if config.responseLimits is http:ResponseLimitConfigs { + httpClientConfig.responseLimits = check config.responseLimits.ensureType(http:ResponseLimitConfigs); + } + if config.secureSocket is http:ClientSecureSocket { + httpClientConfig.secureSocket = check config.secureSocket.ensureType(http:ClientSecureSocket); + } + if config.proxy is http:ProxyConfig { + httpClientConfig.proxy = check config.proxy.ensureType(http:ProxyConfig); + } + } + http:Client httpEp = check new (serviceUrl, httpClientConfig); + self.clientEp = httpEp; + return; + } + + resource isolated function delete '2/dm_events/[DmEventId event_id](map headers = {}) returns DeleteDmResponse|error { + string resourcePath = string `/2/dm_events/${getEncodedUri(event_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/lists/[ListId id](map headers = {}) returns ListDeleteResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/lists/[ListId id]/members/[UserId user_id](map headers = {}) returns ListMutateResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}/members/${getEncodedUri(user_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/tweets/[TweetId id](map headers = {}) returns TweetDeleteResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks/[TweetId tweet_id](map headers = {}) returns BookmarkMutationResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks/${getEncodedUri(tweet_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/followed_lists/[ListId list_id](map headers = {}) returns ListFollowedResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists/${getEncodedUri(list_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/likes/[TweetId tweet_id](map headers = {}) returns UsersLikesDeleteResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/likes/${getEncodedUri(tweet_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists/[ListId list_id](map headers = {}) returns ListUnpinResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists/${getEncodedUri(list_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/retweets/[TweetId source_tweet_id](map headers = {}) returns UsersRetweetsDeleteResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/retweets/${getEncodedUri(source_tweet_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser source_user_id]/following/[UserId target_user_id](map headers = {}) returns UsersFollowingDeleteResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(source_user_id)}/following/${getEncodedUri(target_user_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser source_user_id]/muting/[UserId target_user_id](map headers = {}) returns MuteUserMutationResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(source_user_id)}/muting/${getEncodedUri(target_user_id)}`; + return self.clientEp->delete(resourcePath, headers = headers); + } + + resource isolated function get '2/compliance/jobs(map headers = {}, *ListBatchComplianceJobsQueries queries) returns Get2ComplianceJobsResponse|error { + string resourcePath = string `/2/compliance/jobs`; + map queryParamEncoding = {"compliance_job.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/compliance/jobs/[JobId id](map headers = {}, *GetBatchComplianceJobQueries queries) returns Get2ComplianceJobsIdResponse|error { + string resourcePath = string `/2/compliance/jobs/${getEncodedUri(id)}`; + map queryParamEncoding = {"compliance_job.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/dm_conversations/[DmConversationId id]/dm_events(map headers = {}, *GetDmConversationsIdDmEventsQueries queries) returns Get2DmConversationsIdDmEventsResponse|error { + string resourcePath = string `/2/dm_conversations/${getEncodedUri(id)}/dm_events`; + map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/dm_conversations/with/[UserId participant_id]/dm_events(map headers = {}, *GetDmConversationsWithParticipantIdDmEventsQueries queries) returns Get2DmConversationsWithParticipantIdDmEventsResponse|error { + string resourcePath = string `/2/dm_conversations/with/${getEncodedUri(participant_id)}/dm_events`; + map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/dm_events(map headers = {}, *GetDmEventsQueries queries) returns Get2DmEventsResponse|error { + string resourcePath = string `/2/dm_events`; + map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/dm_events/[DmEventId event_id](map headers = {}, *GetDmEventsByIdQueries queries) returns Get2DmEventsEventIdResponse|error { + string resourcePath = string `/2/dm_events/${getEncodedUri(event_id)}`; + map queryParamEncoding = {"dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/likes/compliance/'stream(map headers = {}, *GetLikesComplianceStreamQueries queries) returns LikesComplianceStreamResponse|error { + string resourcePath = string `/2/likes/compliance/stream`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/likes/firehose/'stream(map headers = {}, *LikesFirehoseStreamQueries queries) returns StreamingLikeResponse|error { + string resourcePath = string `/2/likes/firehose/stream`; + map queryParamEncoding = {"like.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/likes/sample10/'stream(map headers = {}, *LikesSample10StreamQueries queries) returns StreamingLikeResponse|error { + string resourcePath = string `/2/likes/sample10/stream`; + map queryParamEncoding = {"like.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/lists/[ListId id](map headers = {}, *ListIdGetQueries queries) returns Get2ListsIdResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/lists/[ListId id]/followers(map headers = {}, *ListGetFollowersQueries queries) returns Get2ListsIdFollowersResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}/followers`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/lists/[ListId id]/members(map headers = {}, *ListGetMembersQueries queries) returns Get2ListsIdMembersResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}/members`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/lists/[ListId id]/tweets(map headers = {}, *ListsIdTweetsQueries queries) returns Get2ListsIdTweetsResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}/tweets`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/openapi\.json(map headers = {}) returns record {}|error { + string resourcePath = string `/2/openapi.json`; + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces(map headers = {}, *FindSpacesByIdsQueries queries) returns Get2SpacesResponse|error { + string resourcePath = string `/2/spaces`; + map queryParamEncoding = {"ids": {style: FORM, explode: true}, "space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces/'by/creator_ids(map headers = {}, *FindSpacesByCreatorIdsQueries queries) returns Get2SpacesByCreatorIdsResponse|error { + string resourcePath = string `/2/spaces/by/creator_ids`; + map queryParamEncoding = {"user_ids": {style: FORM, explode: true}, "space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces/[string id](map headers = {}, *FindSpaceByIdQueries queries) returns Get2SpacesIdResponse|error { + string resourcePath = string `/2/spaces/${getEncodedUri(id)}`; + map queryParamEncoding = {"space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces/[string id]/buyers(map headers = {}, *SpaceBuyersQueries queries) returns Get2SpacesIdBuyersResponse|error { + string resourcePath = string `/2/spaces/${getEncodedUri(id)}/buyers`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces/[string id]/tweets(map headers = {}, *SpaceTweetsQueries queries) returns Get2SpacesIdTweetsResponse|error { + string resourcePath = string `/2/spaces/${getEncodedUri(id)}/tweets`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/spaces/search(map headers = {}, *SearchSpacesQueries queries) returns Get2SpacesSearchResponse|error { + string resourcePath = string `/2/spaces/search`; + map queryParamEncoding = {"space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/trends/'by/woeid/[int:Signed32 woeid](map headers = {}, *GetTrendsQueries queries) returns Get2TrendsByWoeidWoeidResponse|error { + string resourcePath = string `/2/trends/by/woeid/${getEncodedUri(woeid)}`; + map queryParamEncoding = {"trend.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets(map headers = {}, *FindTweetsByIdQueries queries) returns Get2TweetsResponse|error { + string resourcePath = string `/2/tweets`; + map queryParamEncoding = {"ids": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/[TweetId id](map headers = {}, *FindTweetByIdQueries queries) returns Get2TweetsIdResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/[TweetId id]/liking_users(map headers = {}, *TweetsIdLikingUsersQueries queries) returns Get2TweetsIdLikingUsersResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}/liking_users`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/[TweetId id]/quote_tweets(map headers = {}, *FindTweetsThatQuoteATweetQueries queries) returns Get2TweetsIdQuoteTweetsResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}/quote_tweets`; + map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/[TweetId id]/retweeted_by(map headers = {}, *TweetsIdRetweetingUsersQueries queries) returns Get2TweetsIdRetweetedByResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}/retweeted_by`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/[TweetId id]/retweets(map headers = {}, *FindTweetsThatRetweetATweetQueries queries) returns Get2TweetsIdRetweetsResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(id)}/retweets`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/compliance/'stream(map headers = {}, *GetTweetsComplianceStreamQueries queries) returns TweetComplianceStreamResponse|error { + string resourcePath = string `/2/tweets/compliance/stream`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/counts/all(map headers = {}, *TweetCountsFullArchiveSearchQueries queries) returns Get2TweetsCountsAllResponse|error { + string resourcePath = string `/2/tweets/counts/all`; + map queryParamEncoding = {"search_count.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/counts/recent(map headers = {}, *TweetCountsRecentSearchQueries queries) returns Get2TweetsCountsRecentResponse|error { + string resourcePath = string `/2/tweets/counts/recent`; + map queryParamEncoding = {"search_count.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/firehose/'stream(map headers = {}, *GetTweetsFirehoseStreamQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/firehose/stream`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/firehose/'stream/lang/en(map headers = {}, *GetTweetsFirehoseStreamLangEnQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/firehose/stream/lang/en`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/firehose/'stream/lang/ja(map headers = {}, *GetTweetsFirehoseStreamLangJaQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/firehose/stream/lang/ja`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/firehose/'stream/lang/ko(map headers = {}, *GetTweetsFirehoseStreamLangKoQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/firehose/stream/lang/ko`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/firehose/'stream/lang/pt(map headers = {}, *GetTweetsFirehoseStreamLangPtQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/firehose/stream/lang/pt`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/label/'stream(map headers = {}, *GetTweetsLabelStreamQueries queries) returns TweetLabelStreamResponse|error { + string resourcePath = string `/2/tweets/label/stream`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/sample/'stream(map headers = {}, *SampleStreamQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/2/tweets/sample/stream`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/sample10/'stream(map headers = {}, *GetTweetsSample10StreamQueries queries) returns Get2TweetsSample10StreamResponse|error { + string resourcePath = string `/2/tweets/sample10/stream`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/search/'stream(map headers = {}, *SearchStreamQueries queries) returns FilteredStreamingTweetResponse|error { + string resourcePath = string `/2/tweets/search/stream`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/search/'stream/rules(map headers = {}, *GetRulesQueries queries) returns RulesLookupResponse|error { + string resourcePath = string `/2/tweets/search/stream/rules`; + map queryParamEncoding = {"ids": {style: FORM, explode: true}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/search/'stream/rules/counts(map headers = {}, *GetRuleCountQueries queries) returns Get2TweetsSearchStreamRulesCountsResponse|error { + string resourcePath = string `/2/tweets/search/stream/rules/counts`; + map queryParamEncoding = {"rules_count.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/search/all(map headers = {}, *TweetsFullarchiveSearchQueries queries) returns Get2TweetsSearchAllResponse|error { + string resourcePath = string `/2/tweets/search/all`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/tweets/search/recent(map headers = {}, *TweetsRecentSearchQueries queries) returns Get2TweetsSearchRecentResponse|error { + string resourcePath = string `/2/tweets/search/recent`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/usage/tweets(map headers = {}, *GetUsageTweetsQueries queries) returns Get2UsageTweetsResponse|error { + string resourcePath = string `/2/usage/tweets`; + map queryParamEncoding = {"usage.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users(map headers = {}, *FindUsersByIdQueries queries) returns Get2UsersResponse|error { + string resourcePath = string `/2/users`; + map queryParamEncoding = {"ids": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/'by(map headers = {}, *FindUsersByUsernameQueries queries) returns Get2UsersByResponse|error { + string resourcePath = string `/2/users/by`; + map queryParamEncoding = {"usernames": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/'by/username/[string username](map headers = {}, *FindUserByUsernameQueries queries) returns Get2UsersByUsernameUsernameResponse|error { + string resourcePath = string `/2/users/by/username/${getEncodedUri(username)}`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/blocking(map headers = {}, *UsersIdBlockingQueries queries) returns Get2UsersIdBlockingResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/blocking`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks(map headers = {}, *GetUsersIdBookmarksQueries queries) returns Get2UsersIdBookmarksResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/muting(map headers = {}, *UsersIdMutingQueries queries) returns Get2UsersIdMutingResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/muting`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(map headers = {}, *ListUserPinnedListsQueries queries) returns Get2UsersIdPinnedListsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists`; + map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/timelines/reverse_chronological(map headers = {}, *UsersIdTimelineQueries queries) returns Get2UsersIdTimelinesReverseChronologicalResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/timelines/reverse_chronological`; + map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id](map headers = {}, *FindUserByIdQueries queries) returns Get2UsersIdResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/followed_lists(map headers = {}, *UserFollowedListsQueries queries) returns Get2UsersIdFollowedListsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists`; + map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/followers(map headers = {}, *UsersIdFollowersQueries queries) returns Get2UsersIdFollowersResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/followers`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/following(map headers = {}, *UsersIdFollowingQueries queries) returns Get2UsersIdFollowingResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/following`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/liked_tweets(map headers = {}, *UsersIdLikedTweetsQueries queries) returns Get2UsersIdLikedTweetsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/liked_tweets`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/list_memberships(map headers = {}, *GetUserListMembershipsQueries queries) returns Get2UsersIdListMembershipsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/list_memberships`; + map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/mentions(map headers = {}, *UsersIdMentionsQueries queries) returns Get2UsersIdMentionsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/mentions`; + map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/owned_lists(map headers = {}, *ListUserOwnedListsQueries queries) returns Get2UsersIdOwnedListsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/owned_lists`; + map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/[UserId id]/tweets(map headers = {}, *UsersIdTweetsQueries queries) returns Get2UsersIdTweetsResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/tweets`; + map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/compliance/'stream(map headers = {}, *GetUsersComplianceStreamQueries queries) returns UserComplianceStreamResponse|error { + string resourcePath = string `/2/users/compliance/stream`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/me(map headers = {}, *FindMyUserQueries queries) returns Get2UsersMeResponse|error { + string resourcePath = string `/2/users/me`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function get '2/users/search(map headers = {}, *SearchUserByQueryQueries queries) returns Get2UsersSearchResponse|error { + string resourcePath = string `/2/users/search`; + map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + return self.clientEp->get(resourcePath, headers); + } + + resource isolated function post '2/compliance/jobs(CreateComplianceJobRequest payload, map headers = {}) returns CreateComplianceJobResponse|error { + string resourcePath = string `/2/compliance/jobs`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/dm_conversations(CreateDmConversationRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/2/dm_conversations`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/dm_conversations/[string dm_conversation_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/2/dm_conversations/${getEncodedUri(dm_conversation_id)}/messages`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/dm_conversations/with/[UserId participant_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/2/dm_conversations/with/${getEncodedUri(participant_id)}/messages`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/lists(ListCreateRequest payload, map headers = {}) returns ListCreateResponse|error { + string resourcePath = string `/2/lists`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/lists/[ListId id]/members(ListAddUserRequest payload, map headers = {}) returns ListMutateResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}/members`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/tweets(TweetCreateRequest payload, map headers = {}) returns TweetCreateResponse|error { + string resourcePath = string `/2/tweets`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/tweets/search/'stream/rules(AddOrDeleteRulesRequest payload, map headers = {}, *AddOrDeleteRulesQueries queries) returns AddOrDeleteRulesResponse|error { + string resourcePath = string `/2/tweets/search/stream/rules`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks(BookmarkAddRequest payload, map headers = {}) returns BookmarkMutationResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/followed_lists(ListFollowedRequest payload, map headers = {}) returns ListFollowedResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/following(UsersFollowingCreateRequest payload, map headers = {}) returns UsersFollowingCreateResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/following`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/likes(UsersLikesCreateRequest payload, map headers = {}) returns UsersLikesCreateResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/likes`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/muting(MuteUserRequest payload, map headers = {}) returns MuteUserMutationResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/muting`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(ListPinnedRequest payload, map headers = {}) returns ListPinnedResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/retweets(UsersRetweetsCreateRequest payload, map headers = {}) returns UsersRetweetsCreateResponse|error { + string resourcePath = string `/2/users/${getEncodedUri(id)}/retweets`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->post(resourcePath, request, headers); + } + + resource isolated function put '2/lists/[ListId id](ListUpdateRequest payload, map headers = {}) returns ListUpdateResponse|error { + string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->put(resourcePath, request, headers); + } + + resource isolated function put '2/tweets/[TweetId tweet_id]/hidden(TweetHideRequest payload, map headers = {}) returns TweetHideResponse|error { + string resourcePath = string `/2/tweets/${getEncodedUri(tweet_id)}/hidden`; + http:Request request = new; + json jsonBody = payload.toJson(); + request.setPayload(jsonBody, "application/json"); + return self.clientEp->put(resourcePath, request, headers); + } +} diff --git a/ballerina/types.bal b/ballerina/types.bal new file mode 100644 index 0000000..3bba3ad --- /dev/null +++ b/ballerina/types.bal @@ -0,0 +1,3154 @@ +// AUTO-GENERATED FILE. DO NOT MODIFY. +// This file is auto-generated by the Ballerina OpenAPI tool. + +import ballerina/constraint; +import ballerina/http; + +public type Get2DmConversationsIdDmEventsResponse_meta record { + NextToken next_token?; + PreviousToken previous_token?; + ResultCount result_count?; +}; + +# The previous token. +@constraint:String {minLength: 1} +public type PreviousToken string; + +# Creation time of the compliance job. +public type CreatedAt string; + +public type UsersFollowingCreateResponse_data record { + boolean following?; + boolean pending_follow?; +}; + +public type ListPinnedRequest record { + ListId list_id; +}; + +# Represents the Queries record for the operation: listsIdTweets +public type ListsIdTweetsQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# Represents the Queries record for the operation: getTweetsSample10Stream +public type GetTweetsSample10StreamQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 2} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type UnlikeComplianceSchema record { + # Event time. + string event_at; + UnlikeComplianceSchema_favorite favorite; +}; + +# Represents the Queries record for the operation: listGetFollowers +public type ListGetFollowersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationTokenLong pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type UserComplianceSchema record { + # Event time. + string event_at; + UserComplianceSchema_user user; +}; + +public type Get2SpacesIdResponse record { + Space data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type Tweet_edit_controls record { + # Time when Tweet is no longer editable. + string editable_until; + # Number of times this Tweet can be edited. + int edits_remaining; + # Indicates if this Tweet is eligible to be edited. + boolean is_edit_eligible; +}; + +public type TweetUnviewableSchema record { + TweetUnviewable public_tweet_unviewable; +}; + +# HTTP Status Code. +@constraint:Int {minValue: 100, maxValue: 599} +public type HttpStatusCode int; + +public type ListUpdateResponse_data record { + boolean updated?; +}; + +# Specifies the type of attachments (if any) present in this Tweet. +public type Tweet_attachments record { + # A list of Media Keys for each one of the media attachments (if media are attached). + @constraint:Array {minLength: 1} + MediaKey[] media_keys?; + # A list of Posts the media on this Tweet was originally posted in. For example, if the media on a tweet is re-used in another Tweet, this refers to the original, source Tweet.. + @constraint:Array {minLength: 1} + TweetId[] media_source_tweet_id?; + # A list of poll IDs (if polls are attached). + @constraint:Array {minLength: 1} + PollId[] poll_ids?; +}; + +# Represents the Queries record for the operation: usersIdLikedTweets +public type UsersIdLikedTweetsQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 5, maxValue: 100} + int:Signed32 max_results?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# Tweet label data. +public type TweetLabelData TweetNoticeSchema|TweetUnviewableSchema; + +public type UserScrubGeoObjectSchema record { + # Event time. + string event_at; + TweetId up_to_tweet_id; + UserComplianceSchema_user user; +}; + +# Represents the Queries record for the operation: findUserByUsername +public type FindUserByUsernameQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# A request to create a new batch compliance job. +public type CreateComplianceJobRequest record { + ComplianceJobName name?; + # If true, this endpoint will return a pre-signed URL with resumable uploads enabled. + boolean resumable?; + # Type of compliance job to list. + "tweets"|"users" 'type; +}; + +# Provides a set of configurations for controlling the behaviours when communicating with a remote HTTP endpoint. +@display {label: "Connection Config"} +public type ConnectionConfig record {| + # Configurations related to client authentication + http:BearerTokenConfig|OAuth2RefreshTokenGrantConfig auth; + # The HTTP version understood by the client + http:HttpVersion httpVersion = http:HTTP_2_0; + # Configurations related to HTTP/1.x protocol + ClientHttp1Settings http1Settings?; + # Configurations related to HTTP/2 protocol + http:ClientHttp2Settings http2Settings?; + # The maximum time to wait (in seconds) for a response before closing the connection + decimal timeout = 60; + # The choice of setting `forwarded`/`x-forwarded` header + string forwarded = "disable"; + # Configurations associated with request pooling + http:PoolConfiguration poolConfig?; + # HTTP caching related configurations + http:CacheConfig cache?; + # Specifies the way of handling compression (`accept-encoding`) header + http:Compression compression = http:COMPRESSION_AUTO; + # Configurations associated with the behaviour of the Circuit Breaker + http:CircuitBreakerConfig circuitBreaker?; + # Configurations associated with retrying + http:RetryConfig retryConfig?; + # Configurations associated with inbound response size limits + http:ResponseLimitConfigs responseLimits?; + # SSL/TLS-related options + http:ClientSecureSocket secureSocket?; + # Proxy server related options + http:ProxyConfig proxy?; + # Enables the inbound payload validation functionality which provided by the constraint package. Enabled by default + boolean validation = true; +|}; + +# +public type Space record { + # Creation time of the Space. + string created_at?; + UserId creator_id?; + # End time of the Space. + string ended_at?; + # The user ids for the hosts of the Space. + UserId[] host_ids?; + SpaceId id; + # An array of user ids for people who were invited to a Space. + UserId[] invited_user_ids?; + # Denotes if the Space is a ticketed Space. + boolean is_ticketed?; + # The language of the Space. + string lang?; + # The number of participants in a Space. + int:Signed32 participant_count?; + # A date time stamp for when a Space is scheduled to begin. + string scheduled_start?; + # An array of user ids for people who were speakers in a Space. + UserId[] speaker_ids?; + # When the Space was started as a date string. + string started_at?; + # The current state of the Space. + "live"|"scheduled"|"ended" state; + # The number of people who have either purchased a ticket or set a reminder for this Space. + int:Signed32 subscriber_count?; + # The title of the Space. + string title?; + # The topics of a Space, as selected by its creator. + Space_topics[] topics?; + # When the Space was last updated. + string updated_at?; +}; + +# Represents the Queries record for the operation: getDmEventsById +public type GetDmEventsByIdQueries record { + # A comma separated list of DmEvent fields to display. + ("attachments"|"created_at"|"dm_conversation_id"|"entities"|"event_type"|"id"|"participant_ids"|"referenced_tweets"|"sender_id"|"text")[] dm_event\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"participant_ids"|"referenced_tweets.id"|"sender_id")[] expansions?; +}; + +# Expanded details for the URL specified in the User's profile, with start and end indices. +public type User_entities_url record { + @constraint:Array {minLength: 1} + UrlEntity[] urls?; +}; + +public type UsersRetweetsCreateRequest record {| + TweetId tweet_id; +|}; + +# A response from deleting user-specified stream filtering rules. +public type DeleteRulesRequest record { + DeleteRulesRequest_delete delete; +}; + +# A request to add a user-specified stream filtering rule. +public type AddRulesRequest record { + RuleNoId[] add; +}; + +# Place ID being attached to the Tweet for geo location. +public type TweetCreateRequest_geo record {| + string place_id?; +|}; + +# Represent the portion of text recognized as a URL, and its start and end position within the text. +public type UrlEntityDm record { + *EntityIndicesInclusiveExclusive; + *UrlFields; +}; + +# Annotation inferred from the Tweet text. +public type ContextAnnotation record { + ContextAnnotationDomainFields domain; + ContextAnnotationEntityFields entity; +}; + +public type Get2ListsIdMembersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type UsersFollowingCreateResponse record { + UsersFollowingCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the Queries record for the operation: searchSpaces +public type SearchSpacesQueries record { + # A comma separated list of Space fields to display. + ("created_at"|"creator_id"|"ended_at"|"host_ids"|"id"|"invited_user_ids"|"is_ticketed"|"lang"|"participant_count"|"scheduled_start"|"speaker_ids"|"started_at"|"state"|"subscriber_count"|"title"|"topic_ids"|"updated_at")[] space\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The search query. + @constraint:String {maxLength: 2048, minLength: 1} + string query; + # The number of results to return. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # The state of Spaces to search for. + "live"|"scheduled"|"all" state = "all"; + # A comma separated list of Topic fields to display. + ("description"|"id"|"name")[] topic\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; +}; + +public type UserComplianceSchema_user record { + UserId id; +}; + +# Represent the portion of text recognized as a URL, and its start and end position within the text. +public type UrlEntity record { + *EntityIndicesInclusiveExclusive; + *UrlFields; +}; + +# Represents the Queries record for the operation: getRuleCount +public type GetRuleCountQueries record { + # A comma separated list of RulesCount fields to display. + ("all_project_client_apps"|"cap_per_client_app"|"cap_per_project"|"client_app_rules_count"|"project_rules_count")[] rules_count\.fields?; +}; + +# Represent the portion of text recognized as a User mention, and its start and end position within the text. +public type MentionFields record { + UserId id?; + UserName username; +}; + +public type CreateDmConversationRequest record {| + # The conversation type that is being created. + "Group" conversation_type; + CreateMessageRequest message; + DmParticipants participant_ids; +|}; + +# Represents the Queries record for the operation: findUsersById +public type FindUsersByIdQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A list of User IDs, comma-separated. You can specify up to 100 IDs. + @constraint:Array {maxLength: 100, minLength: 1} + UserId[] ids; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type DeleteDmResponse_data record { + boolean deleted?; +}; + +public type ListUpdateResponse record { + ListUpdateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the data for the context annotation entity. +public type ContextAnnotationEntityFields record { + # Description of the context annotation entity. + string description?; + # The unique id for a context annotation entity. + @constraint:String {pattern: re `^[0-9]{1,19}$`} + string id; + # Name of the context annotation entity. + string name?; +}; + +# Represents the Queries record for the operation: getUserListMemberships +public type GetUserListMembershipsQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationTokenLong pagination_token?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of List fields to display. + ("created_at"|"description"|"follower_count"|"id"|"member_count"|"name"|"owner_id"|"private")[] list\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("owner_id")[] expansions?; +}; + +# Represents the Queries record for the operation: findUserById +public type FindUserByIdQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type ListPinnedResponse_data record { + boolean pinned?; +}; + +public type Get2UsersSearchResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2UsersSearchResponse_meta meta?; +}; + +# Represents the Queries record for the operation: listBatchComplianceJobs +public type ListBatchComplianceJobsQueries record { + # A comma separated list of ComplianceJob fields to display. + ("created_at"|"download_expires_at"|"download_url"|"id"|"name"|"resumable"|"status"|"type"|"upload_expires_at"|"upload_url")[] compliance_job\.fields?; + # Type of Compliance Job to list. + "tweets"|"users" 'type; + # Status of Compliance Job to list. + "created"|"in_progress"|"failed"|"complete" status?; +}; + +public type Get2UsersByUsernameUsernameResponse record { + User data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type ListCreateResponse record { + ListCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type CreateDmEventResponse record { + CreateDmEventResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the Queries record for the operation: tweetsRecentSearch +public type TweetsRecentSearchQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length. + @constraint:String {maxLength: 4096, minLength: 1} + string query; + # YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute). + string end_time?; + # Returns results with a Post ID greater than (that is, more recent than) the specified ID. + TweetId since_id?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 next_token?; + # YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute). + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 pagination_token?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of search results to be returned by a request. + @constraint:Int {minValue: 10, maxValue: 100} + int:Signed32 max_results = 10; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; + # This order in which to return results. + "recency"|"relevancy" sort_order?; + # Returns results with a Post ID less than (that is, older than) the specified ID. + TweetId until_id?; +}; + +# Unique identifier of a DM Event. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type DmEventId string; + +public type DmEvent record { + DmEvent_attachments attachments?; + @constraint:Array {minLength: 1} + CashtagEntity[] cashtags?; + string created_at?; + DmConversationId dm_conversation_id?; + string event_type; + @constraint:Array {minLength: 1} + HashtagEntity[] hashtags?; + DmEventId id; + @constraint:Array {minLength: 1} + MentionEntity[] mentions?; + # A list of participants for a ParticipantsJoin or ParticipantsLeave event_type. + @constraint:Array {minLength: 1} + UserId[] participant_ids?; + # A list of Posts this DM refers to. + @constraint:Array {minLength: 1} + DmEvent_referenced_tweets[] referenced_tweets?; + UserId sender_id?; + string text?; + @constraint:Array {minLength: 1} + UrlEntityDm[] urls?; +}; + +# Represents the Queries record for the operation: getTweetsFirehoseStreamLangEn +public type GetTweetsFirehoseStreamLangEnQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 8} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type LikeComplianceSchema record { + UnlikeComplianceSchema delete; +}; + +public type UsersRetweetsCreateResponse record { + UsersRetweetsCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type Get2TweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type DmEvent_referenced_tweets record { + TweetId id; +}; + +# Represents the Queries record for the operation: getDmEvents +public type GetDmEventsQueries record { + # A comma separated list of DmEvent fields to display. + ("attachments"|"created_at"|"dm_conversation_id"|"entities"|"event_type"|"id"|"participant_ids"|"referenced_tweets"|"sender_id"|"text")[] dm_event\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # The set of event_types to include in the results. + @constraint:Array {minLength: 1} + ("MessageCreate"|"ParticipantsJoin"|"ParticipantsLeave")[] event_types = ["MessageCreate","ParticipantsLeave","ParticipantsJoin"]; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"participant_ids"|"referenced_tweets.id"|"sender_id")[] expansions?; +}; + +# Client App Rule Counts for all applications in the project +public type AllProjectClientApps AppRulesCount[]; + +# The daily usage breakdown for a project +public type Usage_daily_project_usage record { + # The unique identifier for this project + int:Signed32 project_id?; + # The usage value + @constraint:Array {minLength: 1} + UsageFields[] usage?; +}; + +# Specifies the type of attachments (if any) present in this DM. +public type DmEvent_attachments record { + # A list of card IDs (if cards are attached). + @constraint:Array {minLength: 1} + string[] card_ids?; + # A list of Media Keys for each one of the media attachments (if media are attached). + @constraint:Array {minLength: 1} + MediaKey[] media_keys?; +}; + +public type Get2TweetsSearchStreamRulesCountsResponse record { + RulesCount data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type UsersLikesDeleteResponse record { + UsersLikesCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type Get2ListsIdFollowersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type Expansions record { + @constraint:Array {minLength: 1} + Media[] media?; + @constraint:Array {minLength: 1} + Place[] places?; + @constraint:Array {minLength: 1} + Poll[] polls?; + @constraint:Array {minLength: 1} + Topic[] topics?; + @constraint:Array {minLength: 1} + Tweet[] tweets?; + @constraint:Array {minLength: 1} + User[] users?; +}; + +public type TweetCreateResponse_data record { + TweetId id; + TweetText text; +}; + +public type UserDeleteComplianceSchema record { + UserComplianceSchema user_delete; +}; + +# Provides settings related to HTTP/1.x protocol. +public type ClientHttp1Settings record {| + # Specifies whether to reuse a connection for multiple requests + http:KeepAlive keepAlive = http:KEEPALIVE_AUTO; + # The chunking behaviour of the request + http:Chunking chunking = http:CHUNKING_AUTO; + # Proxy server related options + ProxyConfig proxy?; +|}; + +# Unique identifier of this User. The value must be the same as the authenticated user. +public type UserIdMatchesAuthenticatedUser string; + +public type Get2TweetsIdQuoteTweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2TweetsIdQuoteTweetsResponse_meta meta?; +}; + +public type Get2TweetsCountsAllResponse record { + @constraint:Array {minLength: 1} + SearchCount[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Get2TweetsCountsAllResponse_meta meta?; +}; + +# Nonpublic engagement metrics for the Tweet at the time of the request. +public type Tweet_non_public_metrics record { + # Number of times this Tweet has been viewed. + int:Signed32 impression_count?; +}; + +public type Tweet_referenced_tweets record { + TweetId id; + "retweeted"|"quoted"|"replied_to" 'type; +}; + +# User-provided name for a compliance job. +@constraint:String {maxLength: 64} +public type ComplianceJobName string; + +# Represents the Queries record for the operation: listIdGet +public type ListIdGetQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of List fields to display. + ("created_at"|"description"|"follower_count"|"id"|"member_count"|"name"|"owner_id"|"private")[] list\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("owner_id")[] expansions?; +}; + +public type TweetDropComplianceSchema record { + TweetComplianceSchema drop; +}; + +# The sum of results returned in this response. +public type Aggregate int:Signed32; + +public type Get2DmConversationsWithParticipantIdDmEventsResponse record { + @constraint:Array {minLength: 1} + DmEvent[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type ListUpdateRequest record { + @constraint:String {maxLength: 100} + string description?; + @constraint:String {maxLength: 25, minLength: 1} + string name?; + boolean 'private?; +}; + +public type Get2UsersIdFollowedListsResponse record { + @constraint:Array {minLength: 1} + List[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type Place record { + @constraint:Array {minLength: 1} + PlaceId[] contained_within?; + # The full name of the county in which this place exists. + string country?; + CountryCode country_code?; + # The full name of this place. + string full_name; + Geo geo?; + PlaceId id; + # The human readable name of this place. + string name?; + PlaceType place_type?; +}; + +# Represents the Queries record for the operation: getTweetsFirehoseStreamLangJa +public type GetTweetsFirehoseStreamLangJaQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 2} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type UserUnprotectComplianceSchema record { + UserComplianceSchema user_unprotect; +}; + +# User compliance stream events. +public type UserComplianceStreamResponse record {UserComplianceData data;}|record {Problem[] errors;}; + +public type PlaceType "poi"|"neighborhood"|"city"|"admin"|"country"|"unknown"; + +# The start time of the bucket. +public type Start string; + +public type Tweet record { + Tweet_attachments attachments?; + UserId author_id?; + @constraint:Array {minLength: 1} + ContextAnnotation[] context_annotations?; + TweetId conversation_id?; + # Creation time of the Tweet. + string created_at?; + Tweet_edit_controls edit_controls?; + # A list of Tweet Ids in this Tweet chain. + @constraint:Array {minLength: 1} + TweetId[] edit_history_tweet_ids?; + FullTextEntities entities?; + Tweet_geo geo?; + TweetId id?; + UserId in_reply_to_user_id?; + # Language of the Tweet, if detected by X. Returned as a BCP47 language tag. + string lang?; + Tweet_non_public_metrics non_public_metrics?; + Tweet_note_tweet note_tweet?; + Tweet_organic_metrics organic_metrics?; + # Indicates if this Tweet contains URLs marked as sensitive, for example content suitable for mature audiences. + boolean possibly_sensitive?; + Tweet_promoted_metrics promoted_metrics?; + Tweet_public_metrics public_metrics?; + # A list of Posts this Tweet refers to. For example, if the parent Tweet is a Retweet, a Quoted Tweet or a Reply, it will include the related Tweet referenced to by its parent. + @constraint:Array {minLength: 1} + Tweet_referenced_tweets[] referenced_tweets?; + ReplySettingsWithVerifiedUsers reply_settings?; + Tweet_scopes scopes?; + # This is deprecated. + string 'source?; + TweetText text?; + UserName username?; + TweetWithheld withheld?; +}; + +# Type of compliance job to list. +public type ComplianceJobType "tweets"|"users"; + +# A base32 pagination token. +@constraint:String {minLength: 16} +public type PaginationToken32 string; + +public type TweetDeleteResponse_data record { + boolean deleted; +}; + +public type DeleteDmResponse record { + DeleteDmResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Participants for the DM Conversation. +@constraint:Array {maxLength: 49, minLength: 2} +public type DmParticipants UserId[]; + +# The ID of the client application +@constraint:String {maxLength: 19, minLength: 1} +public type ClientAppId string; + +# The unique identifier of this Like. +@constraint:String {pattern: re `^[A-Za-z0-9_]{1,40}$`} +public type LikeId string; + +# Represent the portion of text recognized as a Hashtag, and its start and end position within the text. +public type HashtagFields record { + # The text of the Hashtag. + string tag; +}; + +public type ListMutateResponse_data record { + boolean is_member?; +}; + +# A X List is a curated group of accounts. +public type List record { + string created_at?; + string description?; + int follower_count?; + ListId id; + int member_count?; + # The name of this List. + string name; + UserId owner_id?; + boolean 'private?; +}; + +public type TweetWithheldComplianceSchema record { + TweetTakedownComplianceSchema withheld; +}; + +# URL from which the user will retrieve their compliance results. +public type DownloadUrl string; + +@constraint:String {maxLength: 25, minLength: 1} +public type TweetCreateRequest_pollOptionsItemsString string; + +# A user-provided stream filtering rule. +public type RuleNoId record { + RuleTag tag?; + RuleValue value; +}; + +public type UserProfileModificationObjectSchema record { + # Event time. + string event_at; + string new_value; + string profile_field; + UserComplianceSchema_user user; +}; + +public type ListFollowedResponse record { + ListFollowedResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type Get2UsersByResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type Get2TweetsCountsRecentResponse record { + @constraint:Array {minLength: 1} + SearchCount[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Get2TweetsCountsAllResponse_meta meta?; +}; + +# Represents the Queries record for the operation: searchUserByQuery +public type SearchUserByQueryQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # TThe the query string by which to query for users. + UserSearchQuery query; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results = 100; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 next_token?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# The unique identifier of this Media. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type MediaId string; + +public type Get2UsersIdFollowingResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# An HTTP Problem Details object, as defined in IETF RFC 7807 (https://tools.ietf.org/html/rfc7807). +public type Problem record { + string detail?; + int status?; + string title; + string 'type; +}; + +public type UnlikeComplianceSchema_favorite record { + TweetId id; + UserId user_id; +}; + +# A count of user-provided stream filtering rules at the application and project levels. +public type RulesCount record { + AllProjectClientApps all_project_client_apps?; + # Cap of number of rules allowed per client application + int:Signed32 cap_per_client_app?; + # Cap of number of rules allowed per project + int:Signed32 cap_per_project?; + AppRulesCount client_app_rules_count?; + # Number of rules for project + int:Signed32 project_rules_count?; +}; + +public type Get2TweetsIdRetweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# The end time of the bucket. +public type End string; + +public type FilteredStreamingTweetResponse_matching_rules record { + RuleId id; + RuleTag tag?; +}; + +public type MuteUserRequest record { + UserId target_user_id; +}; + +# A list of metadata found in the User's profile description. +public type User_entities record { + FullTextEntities description?; + User_entities_url url?; +}; + +# URL to which the user will upload their Tweet or user IDs. +public type UploadUrl string; + +public type RulesResponseMetadata record { + NextToken next_token?; + # Number of Rules in result set. + int:Signed32 result_count?; + string sent; + RulesRequestSummary summary?; +}; + +# Promoted nonpublic engagement metrics for the Tweet at the time of the request. +public type Tweet_promoted_metrics record { + # Number of times this Tweet has been viewed. + int:Signed32 impression_count?; + # Number of times this Tweet has been liked. + int:Signed32 like_count?; + # Number of times this Tweet has been replied to. + int:Signed32 reply_count?; + # Number of times this Tweet has been Retweeted. + int:Signed32 retweet_count?; +}; + +# The content of the Tweet. +public type TweetText string; + +# A list of metrics for this User. +public type User_public_metrics record { + # Number of Users who are following this User. + int followers_count; + # Number of Users this User is following. + int following_count; + # The number of likes created by this User. + int like_count?; + # The number of lists that include this User. + int listed_count; + # The number of Posts (including Retweets) posted by this User. + int tweet_count; +}; + +# Represents the Queries record for the operation: getTweetsFirehoseStreamLangPt +public type GetTweetsFirehoseStreamLangPtQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 2} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type TweetComplianceSchema_tweet record { + UserId author_id; + TweetId id; +}; + +public type ListAddUserRequest record { + UserId user_id; +}; + +# The text of a poll choice. +@constraint:String {maxLength: 25, minLength: 1} +public type PollOptionLabel string; + +public type TweetHideRequest record { + boolean hidden; +}; + +public type AddOrDeleteRulesRequest AddRulesRequest|DeleteRulesRequest; + +# Represents the Queries record for the operation: spaceBuyers +public type SpaceBuyersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type RulesLookupResponse record { + Rule[] data?; + RulesResponseMetadata meta; +}; + +public type ListUnpinResponse record { + ListPinnedResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type CreateDmEventResponse_data record { + DmConversationId dm_conversation_id; + DmEventId dm_event_id; +}; + +public type UsersLikesCreateResponse record { + UsersLikesCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type Get2SpacesResponse record { + @constraint:Array {minLength: 1} + Space[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type FullTextEntities record { + @constraint:Array {minLength: 1} + record {*EntityIndicesInclusiveInclusive; string normalized_text?; decimal probability?; string 'type?;}[] annotations?; + @constraint:Array {minLength: 1} + CashtagEntity[] cashtags?; + @constraint:Array {minLength: 1} + HashtagEntity[] hashtags?; + @constraint:Array {minLength: 1} + MentionEntity[] mentions?; + @constraint:Array {minLength: 1} + UrlEntity[] urls?; +}; + +# OAuth2 Refresh Token Grant Configs +public type OAuth2RefreshTokenGrantConfig record {| + *http:OAuth2RefreshTokenGrantConfig; + # Refresh URL + string refreshUrl = "https://api.twitter.com/2/oauth2/token"; +|}; + +# Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is exclusive. +public type EntityIndicesInclusiveExclusive record { + # Index (zero-based) at which position this entity ends. The index is exclusive. + @constraint:Int {minValue: 0} + int end; + # Index (zero-based) at which position this entity starts. The index is inclusive. + @constraint:Int {minValue: 0} + int 'start; +}; + +# Describes a choice in a Poll object. +public type PollOption record { + PollOptionLabel label; + # Position of this choice in the poll. + int position; + # Number of users who voted for this choice. + int votes; +}; + +# Represents the Queries record for the operation: getDmConversationsIdDmEvents +public type GetDmConversationsIdDmEventsQueries record { + # A comma separated list of DmEvent fields to display. + ("attachments"|"created_at"|"dm_conversation_id"|"entities"|"event_type"|"id"|"participant_ids"|"referenced_tweets"|"sender_id"|"text")[] dm_event\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # The set of event_types to include in the results. + @constraint:Array {minLength: 1} + ("MessageCreate"|"ParticipantsJoin"|"ParticipantsLeave")[] event_types = ["MessageCreate","ParticipantsLeave","ParticipantsJoin"]; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"participant_ids"|"referenced_tweets.id"|"sender_id")[] expansions?; +}; + +# The the search string by which to query for users. +@constraint:String {pattern: re `^[A-Za-z0-9_]{1,32}$`} +public type UserSearchQuery string; + +# Represents the Queries record for the operation: findTweetById +public type FindTweetByIdQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type ListFollowedResponse_data record { + boolean following?; +}; + +# The X handle (screen name) of this user. +@constraint:String {pattern: re `^[A-Za-z0-9_]{1,15}$`} +public type UserName string; + +# Represents the Queries record for the operation: getUsageTweets +public type GetUsageTweetsQueries record { + # A comma separated list of Usage fields to display. + ("cap_reset_day"|"daily_client_app_usage"|"daily_project_usage"|"project_cap"|"project_id"|"project_usage")[] usage\.fields?; + # The number of days for which you need usage for. + @constraint:Int {minValue: 1, maxValue: 90} + int:Signed32 days = 7; +}; + +# Represents the Queries record for the operation: getTweetsFirehoseStreamLangKo +public type GetTweetsFirehoseStreamLangKoQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 2} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +@constraint:String {pattern: re `^[a-zA-Z0-9]{1,13}$`} +public type FindSpacesByIdsQueriesIdsItemsString string; + +public type UsersFollowingDeleteResponse record { + ListFollowedResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# The X Topic object. +public type Space_topics record { + # The description of the given topic. + string description?; + # An ID suitable for use in the REST API. + string id; + # The name of the given topic. + string name; +}; + +public type Get2ComplianceJobsResponse record { + @constraint:Array {minLength: 1} + ComplianceJob[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Get2ComplianceJobsResponse_meta meta?; +}; + +public type UsersFollowingCreateRequest record { + UserId target_user_id; +}; + +# Usage per client app +public type ClientAppUsage record { + # The unique identifier for this project + string client_app_id?; + # The usage value + @constraint:Array {minLength: 1} + UsageFields[] usage?; + # The number of results returned + int:Signed32 usage_result_count?; +}; + +# Tweet information of the Tweet being replied to. +public type TweetCreateRequest_reply record {| + # A list of User Ids to be excluded from the reply Tweet. + UserId[] exclude_reply_user_ids?; + TweetId in_reply_to_tweet_id; +|}; + +public type Get2TrendsByWoeidWoeidResponse record { + @constraint:Array {minLength: 1} + Trend[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the Queries record for the operation: findSpaceById +public type FindSpaceByIdQueries record { + # A comma separated list of Space fields to display. + ("created_at"|"creator_id"|"ended_at"|"host_ids"|"id"|"invited_user_ids"|"is_ticketed"|"lang"|"participant_count"|"scheduled_start"|"speaker_ids"|"started_at"|"state"|"subscriber_count"|"title"|"topic_ids"|"updated_at")[] space\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Topic fields to display. + ("description"|"id"|"name")[] topic\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; +}; + +public type CreateAttachmentsMessageRequest record { + DmAttachments attachments; + # Text of the message. + @constraint:String {minLength: 1} + string text?; +}; + +# Represents the Queries record for the operation: spaceTweets +public type SpaceTweetsQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The number of Posts to fetch from the provided space. If not provided, the value will default to the maximum of 100. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type StreamingTweetResponse record { + Tweet data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type Get2TweetsIdResponse record { + Tweet data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +# Represents the Queries record for the operation: getTrends +public type GetTrendsQueries record { + # A comma separated list of Trend fields to display. + ("trend_name"|"tweet_count")[] trend\.fields?; +}; + +public type TweetHideResponse_data record { + boolean hidden?; +}; + +# Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country). +public type TweetWithheld record { + # Indicates if the content is being withheld for on the basis of copyright infringement. + boolean copyright; + # Provides a list of countries where this content is not available. + @constraint:Array {minLength: 1} + CountryCode[] country_codes; + # Indicates whether the content being withheld is the `tweet` or a `user`. + "tweet"|"user" scope?; +}; + +public type UsersRetweetsDeleteResponse_data record { + boolean retweeted?; +}; + +# IDs and values of all deleted user-specified stream filtering rules. +public type DeleteRulesRequest_delete record { + # IDs of all deleted user-specified stream filtering rules. + RuleId[] ids?; + # Values of all deleted user-specified stream filtering rules. + RuleValue[] values?; +}; + +# A count of user-provided stream filtering rules at the client application level. +public type AppRulesCount record { + ClientAppId client_app_id?; + # Number of rules for client application + int:Signed32 rule_count?; +}; + +public type UserProtectComplianceSchema record { + UserComplianceSchema user_protect; +}; + +public type StreamingLikeResponse record { + Like data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +@constraint:Number {minValue: -180, maxValue: 180} +public type GeoBboxItemsNumber decimal; + +# Represents the Queries record for the operation: listUserOwnedLists +public type ListUserOwnedListsQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationTokenLong pagination_token?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of List fields to display. + ("created_at"|"description"|"follower_count"|"id"|"member_count"|"name"|"owner_id"|"private")[] list\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("owner_id")[] expansions?; +}; + +# Represents the Queries record for the operation: getDmConversationsWithParticipantIdDmEvents +public type GetDmConversationsWithParticipantIdDmEventsQueries record { + # A comma separated list of DmEvent fields to display. + ("attachments"|"created_at"|"dm_conversation_id"|"entities"|"event_type"|"id"|"participant_ids"|"referenced_tweets"|"sender_id"|"text")[] dm_event\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # The set of event_types to include in the results. + @constraint:Array {minLength: 1} + ("MessageCreate"|"ParticipantsJoin"|"ParticipantsLeave")[] event_types = ["MessageCreate","ParticipantsLeave","ParticipantsJoin"]; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"participant_ids"|"referenced_tweets.id"|"sender_id")[] expansions?; +}; + +# Tweet compliance stream events. +public type TweetComplianceStreamResponse record {TweetComplianceData data;}|record {Problem[] errors;}; + +public type Get2SpacesIdBuyersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type UserWithheldComplianceSchema record { + UserTakedownComplianceSchema user_withheld; +}; + +public type Tweet_note_tweet_entities record { + @constraint:Array {minLength: 1} + CashtagEntity[] cashtags?; + @constraint:Array {minLength: 1} + HashtagEntity[] hashtags?; + @constraint:Array {minLength: 1} + MentionEntity[] mentions?; + @constraint:Array {minLength: 1} + UrlEntity[] urls?; +}; + +public type DmMediaAttachment record { + MediaId media_id; +}; + +public type Get2UsersIdBlockingResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# The number of results returned in this response. +public type ResultCount int:Signed32; + +public type Get2UsersIdFollowersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type UserSuspendComplianceSchema record { + UserComplianceSchema user_suspend; +}; + +public type Get2TweetsIdLikingUsersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type CashtagEntity record { + *EntityIndicesInclusiveExclusive; + *CashtagFields; +}; + +# Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type TweetId string; + +public type UsersLikesCreateResponse_data record { + boolean liked?; +}; + +public type HashtagEntity record { + *EntityIndicesInclusiveExclusive; + *HashtagFields; +}; + +# Represents the Queries record for the operation: findTweetsThatQuoteATweet +public type FindTweetsThatQuoteATweetQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results to be returned. + @constraint:Int {minValue: 10, maxValue: 100} + int:Signed32 max_results = 10; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # The set of entities to exclude (e.g. 'replies' or 'retweets'). + @constraint:Array {minLength: 1} + ("replies"|"retweets")[] exclude?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# Organic nonpublic engagement metrics for the Tweet at the time of the request. +public type Tweet_organic_metrics record { + # Number of times this Tweet has been viewed. + int impression_count; + # Number of times this Tweet has been liked. + int like_count; + # Number of times this Tweet has been replied to. + int reply_count; + # Number of times this Tweet has been Retweeted. + int retweet_count; +}; + +# Represents the Queries record for the operation: listGetMembers +public type ListGetMembersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationTokenLong pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# Expiration time of the download URL. +public type DownloadExpiration string; + +public type UserUndeleteComplianceSchema record { + UserComplianceSchema user_undelete; +}; + +# Represents the Queries record for the operation: getUsersComplianceStream +public type GetUsersComplianceStreamQueries record { + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the User Compliance events will be provided. + string start_time?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 4} + int:Signed32 partition; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the User Compliance events will be provided. + string end_time?; +}; + +public type Get2ListsIdResponse record { + List data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type ComplianceJob record { + CreatedAt created_at; + DownloadExpiration download_expires_at; + DownloadUrl download_url; + JobId id; + ComplianceJobName name?; + ComplianceJobStatus status; + ComplianceJobType 'type; + UploadExpiration upload_expires_at; + UploadUrl upload_url; +}; + +# A [GeoJson Position](https://tools.ietf.org/html/rfc7946#section-3.1.1) in the format `[longitude,latitude]`. +@constraint:Array {maxLength: 2, minLength: 2} +public type Position decimal[]; + +# Represents the Queries record for the operation: userFollowedLists +public type UserFollowedListsQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationTokenLong pagination_token?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of List fields to display. + ("created_at"|"description"|"follower_count"|"id"|"member_count"|"name"|"owner_id"|"private")[] list\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("owner_id")[] expansions?; +}; + +# The note content of the Tweet. +public type NoteTweetText string; + +public type BookmarkMutationResponse record { + BookmarkMutationResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the data for Usage +public type UsageFields record { + # The time period for the usage + string date?; + # The usage value + int:Signed32 usage?; +}; + +public type Geo record { + @constraint:Array {maxLength: 4, minLength: 4} + GeoBboxItemsNumber[] bbox; + Point geometry?; + record {} properties; + "Feature" 'type; +}; + +# Represents the Queries record for the operation: searchStream +public type SearchStreamQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type Get2UsersIdTweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2UsersIdMentionsResponse_meta meta?; +}; + +# Represents the Queries record for the operation: usersIdMentions +public type UsersIdMentionsQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified. + string end_time?; + # The maximum number of results. + @constraint:Int {minValue: 5, maxValue: 100} + int:Signed32 max_results?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified. + TweetId since_id?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; + # The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified. + TweetId until_id?; +}; + +public type TweetEditComplianceObjectSchema record { + @constraint:Array {minLength: 1} + TweetId[] edit_tweet_ids; + # Event time. + string event_at; + TweetId initial_tweet_id; + DmEvent_referenced_tweets tweet; +}; + +public type Get2UsersMeResponse record { + User data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +# Tweet compliance data. +public type TweetComplianceData TweetDeleteComplianceSchema|TweetWithheldComplianceSchema|TweetDropComplianceSchema|TweetUndropComplianceSchema|TweetEditComplianceSchema; + +public type MuteUserMutationResponse record { + MuteUserMutationResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# A user-provided stream filtering rule. +public type Rule record { + RuleId id?; + RuleTag tag?; + RuleValue value; +}; + +public type ListFollowedRequest record { + ListId list_id; +}; + +# Represents the Queries record for the operation: findTweetsThatRetweetATweet +public type FindTweetsThatRetweetATweetQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type RulesRequestSummary record {int:Signed32 created; int:Signed32 invalid; int:Signed32 not_created; int:Signed32 valid;}|record {int:Signed32 deleted; int:Signed32 not_deleted;}; + +# Represents the Queries record for the operation: findTweetsById +public type FindTweetsByIdQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # A comma separated list of Post IDs. Up to 100 are allowed in a single request. + @constraint:Array {maxLength: 100, minLength: 1} + TweetId[] ids; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# A X List is a curated group of accounts. +public type ListCreateResponse_data record { + ListId id; + # The name of this List. + string name; +}; + +public type TweetNoticeSchema record { + TweetNotice public_tweet_notice; +}; + +# Represents the Queries record for the operation: getRules +public type GetRulesQueries record { + # This value is populated by passing the 'next_token' returned in a request to paginate through results. + @constraint:String {maxLength: 16, minLength: 16} + string pagination_token?; + # A comma-separated list of Rule IDs. + RuleId[] ids?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results = 1000; +}; + +# User compliance data. +public type UserComplianceData UserProtectComplianceSchema|UserUnprotectComplianceSchema|UserDeleteComplianceSchema|UserUndeleteComplianceSchema|UserSuspendComplianceSchema|UserUnsuspendComplianceSchema|UserWithheldComplianceSchema|UserScrubGeoSchema|UserProfileModificationComplianceSchema; + +public type ListPinnedResponse record { + ListPinnedResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +public type TweetNotice record { + # If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’. + string application; + # Information shown on the Tweet label + string details?; + # Event time. + string event_at; + # The type of label on the Tweet + string event_type; + # Link to more information about this kind of label + string extended_details_url?; + # Title/header of the Tweet label + string label_title?; + TweetComplianceSchema_tweet tweet; +}; + +# A validly formatted URL. +public type Url string; + +# Represents the Queries record for the operation: tweetsIdLikingUsers +public type TweetsIdLikingUsersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type CreateTextMessageRequest record { + DmAttachments attachments?; + # Text of the message. + @constraint:String {minLength: 1} + string text; +}; + +public type Get2SpacesIdTweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# Represents the Queries record for the operation: likesSample10Stream +public type LikesSample10StreamQueries record { + # A comma separated list of Like fields to display. + ("created_at"|"id"|"liked_tweet_id"|"timestamp_ms")[] like\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided. + string start_time?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 2} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("liked_tweet_id")[] expansions?; +}; + +# Represents the Queries record for the operation: usersIdFollowers +public type UsersIdFollowersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# Represents the Queries record for the operation: getTweetsComplianceStream +public type GetTweetsComplianceStreamQueries record { + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post Compliance events will be provided. + string start_time?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 4} + int:Signed32 partition; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Post Compliance events will be provided. + string end_time?; +}; + +# The count for the bucket. +public type TweetCount int; + +# Represents the Queries record for the operation: addOrDeleteRules +public type AddOrDeleteRulesQueries record { + # Dry Run can be used with both the add and delete action, with the expected result given, but without actually taking any action in the system (meaning the end state will always be as it was when the request was submitted). This is particularly useful to validate rule changes. + boolean dry_run?; + # Delete All can be used to delete all of the rules associated this client app, it should be specified with no other parameters. Once deleted, rules cannot be recovered. + boolean delete_all?; +}; + +# A tag meant for the labeling of user provided rules. +public type RuleTag string; + +public type Get2TweetsIdRetweetedByResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type FullTextEntitiesAnnotationsItemsnull record { + *EntityIndicesInclusiveInclusive; + string normalized_text?; + decimal probability?; + string 'type?; +}; + +# Represents the Queries record for the operation: usersIdMuting +public type UsersIdMutingQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationTokenLong pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# Represents the Queries record for the operation: getTweetsLabelStream +public type GetTweetsLabelStreamQueries record { + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post labels will be provided. + string start_time?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Post labels will be provided. + string end_time?; +}; + +# Represent the portion of text recognized as a URL. +public type UrlFields record { + # Description of the URL landing page. + string description?; + # The URL as displayed in the X client. + string display_url?; + Url expanded_url?; + @constraint:Array {minLength: 1} + UrlImage[] images?; + MediaKey media_key?; + HttpStatusCode status?; + # Title of the page the URL points to. + string title?; + # Fully resolved url. + string unwound_url?; + Url url; +}; + +# Usage per client app +public type Usage record { + # Number of days left for the Tweet cap to reset + int:Signed32 cap_reset_day?; + # The daily usage breakdown for each Client Application a project + @constraint:Array {minLength: 1} + ClientAppUsage[] daily_client_app_usage?; + Usage_daily_project_usage daily_project_usage?; + # Total number of Posts that can be read in this project per month + int:Signed32 project_cap?; + # The unique identifier for this project + string project_id?; + # The number of Posts read in this project + int:Signed32 project_usage?; +}; + +public type Get2UsersIdListMembershipsResponse record { + @constraint:Array {minLength: 1} + List[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type TweetCreateRequest record {| + # Card Uri Parameter. This is mutually exclusive from Quote Tweet Id, Poll, Media, and Direct Message Deep Link. + string card_uri?; + # Link to take the conversation from the public timeline to a private Direct Message. + string direct_message_deep_link?; + # Exclusive Tweet for super followers. + boolean for_super_followers_only = false; + TweetCreateRequest_geo geo?; + TweetCreateRequest_media media?; + # Nullcasted (promoted-only) Posts do not appear in the public timeline and are not served to followers. + boolean nullcast = false; + TweetCreateRequest_poll poll?; + TweetId quote_tweet_id?; + TweetCreateRequest_reply reply?; + # Settings to indicate who can reply to the Tweet. + "following"|"mentionedUsers"|"subscribers" reply_settings?; + TweetText text?; +|}; + +public type TweetDeleteComplianceSchema record { + TweetComplianceSchema delete; +}; + +public type MuteUserMutationResponse_data record { + boolean muting?; +}; + +public type Get2SpacesSearchResponse record { + @constraint:Array {minLength: 1} + Space[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2ComplianceJobsResponse_meta meta?; +}; + +# Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, subscribers, verified and following. +public type ReplySettingsWithVerifiedUsers "everyone"|"mentionedUsers"|"following"|"other"|"subscribers"|"verified"; + +# Represents the Queries record for the operation: findUsersByUsername +public type FindUsersByUsernameQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A list of usernames, comma-separated. + @constraint:Array {maxLength: 100, minLength: 1} + FindUsersByUsernameQueriesUsernamesItemsString[] usernames; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type TweetComplianceSchema record { + # Event time. + string event_at; + TweetId quote_tweet_id?; + TweetComplianceSchema_tweet tweet; +}; + +# A base36 pagination token. +@constraint:String {minLength: 1} +public type PaginationToken36 string; + +# Engagement metrics for the Tweet at the time of the request. +public type Tweet_public_metrics record { + # Number of times this Tweet has been bookmarked. + int:Signed32 bookmark_count; + # Number of times this Tweet has been viewed. + int:Signed32 impression_count; + # Number of times this Tweet has been liked. + int like_count; + # Number of times this Tweet has been quoted. + int quote_count?; + # Number of times this Tweet has been replied to. + int reply_count; + # Number of times this Tweet has been Retweeted. + int retweet_count; +}; + +# Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is inclusive. +public type EntityIndicesInclusiveInclusive record { + # Index (zero-based) at which position this entity ends. The index is inclusive. + @constraint:Int {minValue: 0} + int end; + # Index (zero-based) at which position this entity starts. The index is inclusive. + @constraint:Int {minValue: 0} + int 'start; +}; + +public type Get2TweetsSearchAllResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2TweetsSearchAllResponse_meta meta?; +}; + +public type BookmarkAddRequest record { + TweetId tweet_id; +}; + +public type TweetTakedownComplianceSchema record { + # Event time. + string event_at; + TweetId quote_tweet_id?; + TweetComplianceSchema_tweet tweet; + @constraint:Array {minLength: 1} + CountryCode[] withheld_in_countries; +}; + +# Represents the Queries record for the operation: findMyUser +public type FindMyUserQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# Likes compliance stream events. +public type LikesComplianceStreamResponse record {LikeComplianceSchema data;}|record {Problem[] errors;}; + +public type Get2TweetsSample10StreamResponse record { + Tweet data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +# Represent the information for the URL image. +public type UrlImage record { + MediaHeight height?; + Url url?; + MediaWidth width?; +}; + +public type ListMutateResponse record { + ListMutateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +@constraint:String {pattern: re `^[A-Za-z0-9_]{1,15}$`} +public type FindUsersByUsernameQueriesUsernamesItemsString string; + +# Represents the Queries record for the operation: sampleStream +public type SampleStreamQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# The newest id in this response. +public type NewestId string; + +# Represents the Queries record for the operation: tweetsIdRetweetingUsers +public type TweetsIdRetweetingUsersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results = 100; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +public type Get2UsersIdLikedTweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# Unique identifier of this poll. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type PollId string; + +public type Get2TweetsSearchRecentResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2TweetsSearchAllResponse_meta meta?; +}; + +# Attachments to a DM Event. +public type DmAttachments DmMediaAttachment[]; + +# Represents the Queries record for the operation: getBatchComplianceJob +public type GetBatchComplianceJobQueries record { + # A comma separated list of ComplianceJob fields to display. + ("created_at"|"download_expires_at"|"download_url"|"id"|"name"|"resumable"|"status"|"type"|"upload_expires_at"|"upload_url")[] compliance_job\.fields?; +}; + +# Represents the Queries record for the operation: likesFirehoseStream +public type LikesFirehoseStreamQueries record { + # A comma separated list of Like fields to display. + ("created_at"|"id"|"liked_tweet_id"|"timestamp_ms")[] like\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided. + string start_time?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 20} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("liked_tweet_id")[] expansions?; +}; + +# The filterlang value of the rule. +public type RuleValue string; + +# Represent the portion of text recognized as a Cashtag, and its start and end position within the text. +public type CashtagFields record { + string tag; +}; + +# Unique identifier of a DM conversation. This can either be a numeric string, or a pair of numeric strings separated by a '-' character in the case of one-on-one DM Conversations. +@constraint:String {pattern: re `^([0-9]{1,19}-[0-9]{1,19}|[0-9]{15,19})$`} +public type DmConversationId string; + +public type UserScrubGeoSchema record { + UserScrubGeoObjectSchema scrub_geo; +}; + +# Represents the Queries record for the operation: findSpacesByCreatorIds +public type FindSpacesByCreatorIdsQueries record { + # A comma separated list of Space fields to display. + ("created_at"|"creator_id"|"ended_at"|"host_ids"|"id"|"invited_user_ids"|"is_ticketed"|"lang"|"participant_count"|"scheduled_start"|"speaker_ids"|"started_at"|"state"|"subscriber_count"|"title"|"topic_ids"|"updated_at")[] space\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The IDs of Users to search through. + @constraint:Array {maxLength: 100, minLength: 1} + UserId[] user_ids; + # A comma separated list of Topic fields to display. + ("description"|"id"|"name")[] topic\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; +}; + +public type Get2TweetsIdQuoteTweetsResponse_meta record { + NextToken next_token?; + ResultCount result_count?; +}; + +public type Get2DmEventsResponse record { + @constraint:Array {minLength: 1} + DmEvent[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# A Like event, with the liking user and the tweet being liked +public type Like record { + # Creation time of the Tweet. + string created_at?; + LikeId id?; + TweetId liked_tweet_id?; + UserId liking_user_id?; + # Timestamp in milliseconds of creation. + int:Signed32 timestamp_ms?; +}; + +public type TweetHideResponse record { + TweetHideResponse_data data?; +}; + +public type Get2UsersIdBookmarksResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type Get2UsersIdMentionsResponse_meta record { + NewestId newest_id?; + NextToken next_token?; + OldestId oldest_id?; + PreviousToken previous_token?; + ResultCount result_count?; +}; + +public type Get2UsageTweetsResponse record { + Usage data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# The width of the media in pixels. +@constraint:Int {minValue: 0} +public type MediaWidth int; + +# Media information being attached to created Tweet. This is mutually exclusive from Quote Tweet Id, Poll, and Card URI. +public type TweetCreateRequest_media record {| + # A list of Media Ids to be attached to a created Tweet. + @constraint:Array {maxLength: 4, minLength: 1} + MediaId[] media_ids; + # A list of User Ids to be tagged in the media for created Tweet. + @constraint:Array {maxLength: 10} + UserId[] tagged_user_ids?; +|}; + +public type BookmarkMutationResponse_data record { + boolean bookmarked?; +}; + +public type Get2SpacesByCreatorIdsResponse record { + @constraint:Array {minLength: 1} + Space[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2ComplianceJobsResponse_meta meta?; +}; + +# The oldest id in this response. +public type OldestId string; + +public type Get2UsersIdOwnedListsResponse record { + @constraint:Array {minLength: 1} + List[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type CreateComplianceJobResponse record { + ComplianceJob data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represent a Search Count Result. +public type SearchCount record { + End end; + Start 'start; + TweetCount tweet_count; +}; + +# Represents the data for the context annotation domain. +public type ContextAnnotationDomainFields record { + # Description of the context annotation domain. + string description?; + # The unique id for a context annotation domain. + @constraint:String {pattern: re `^[0-9]{1,19}$`} + string id; + # Name of the context annotation domain. + string name?; +}; + +# The identifier for this place. +public type PlaceId string; + +# The scopes for this tweet +public type Tweet_scopes record { + # Indicates if this Tweet is viewable by followers without the Tweet ID + boolean followers?; +}; + +public type Get2TweetsSearchAllResponse_meta record { + NewestId newest_id?; + NextToken next_token?; + OldestId oldest_id?; + ResultCount result_count?; +}; + +public type Get2UsersIdTimelinesReverseChronologicalResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2UsersIdMentionsResponse_meta meta?; +}; + +# Represents the Queries record for the operation: usersIdBlocking +public type UsersIdBlockingQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# Represents the Queries record for the operation: listUserPinnedLists +public type ListUserPinnedListsQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # A comma separated list of List fields to display. + ("created_at"|"description"|"follower_count"|"id"|"member_count"|"name"|"owner_id"|"private")[] list\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("owner_id")[] expansions?; +}; + +public type Media record { + MediaHeight height?; + MediaKey media_key?; + string 'type; + MediaWidth width?; +}; + +# A 'long' pagination token. +@constraint:String {maxLength: 19, minLength: 1} +public type PaginationTokenLong string; + +# A trend. +public type Trend record { + # Name of the trend. + string trend_name?; + # Number of Posts in this trend. + int:Signed32 tweet_count?; +}; + +# The full-content of the Tweet, including text beyond 280 characters. +public type Tweet_note_tweet record { + Tweet_note_tweet_entities entities?; + NoteTweetText text?; +}; + +# Represents the Queries record for the operation: tweetCountsFullArchiveSearch +public type TweetCountsFullArchiveSearchQueries record { + # YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute). + string start_time?; + # A comma separated list of SearchCount fields to display. + ("end"|"start"|"tweet_count")[] search_count\.fields?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 pagination_token?; + # The granularity for the search counts results. + "minute"|"hour"|"day" granularity = "hour"; + # One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length. + @constraint:String {maxLength: 4096, minLength: 1} + string query; + # YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute). + string end_time?; + # Returns results with a Post ID greater than (that is, more recent than) the specified ID. + TweetId since_id?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 next_token?; + # Returns results with a Post ID less than (that is, older than) the specified ID. + TweetId until_id?; +}; + +public type UsersRetweetsDeleteResponse record { + UsersRetweetsDeleteResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# A response from modifying user-specified stream filtering rules. +public type AddOrDeleteRulesResponse record { + # All user-specified stream filtering rules that were created. + Rule[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + RulesResponseMetadata meta; +}; + +# Represents the Queries record for the operation: findSpacesByIds +public type FindSpacesByIdsQueries record { + # A comma separated list of Space fields to display. + ("created_at"|"creator_id"|"ended_at"|"host_ids"|"id"|"invited_user_ids"|"is_ticketed"|"lang"|"participant_count"|"scheduled_start"|"speaker_ids"|"started_at"|"state"|"subscriber_count"|"title"|"topic_ids"|"updated_at")[] space\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The list of Space IDs to return. + @constraint:Array {maxLength: 100, minLength: 1} + FindSpacesByIdsQueriesIdsItemsString[] ids; + # A comma separated list of Topic fields to display. + ("description"|"id"|"name")[] topic\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; +}; + +public type Get2ComplianceJobsIdResponse record { + ComplianceJob data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Represents the Queries record for the operation: tweetCountsRecentSearch +public type TweetCountsRecentSearchQueries record { + # YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute). + string start_time?; + # A comma separated list of SearchCount fields to display. + ("end"|"start"|"tweet_count")[] search_count\.fields?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 pagination_token?; + # The granularity for the search counts results. + "minute"|"hour"|"day" granularity = "hour"; + # One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length. + @constraint:String {maxLength: 4096, minLength: 1} + string query; + # YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute). + string end_time?; + # Returns results with a Post ID greater than (that is, more recent than) the specified ID. + TweetId since_id?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 next_token?; + # Returns results with a Post ID less than (that is, older than) the specified ID. + TweetId until_id?; +}; + +# The location tagged on the Tweet, if the user provided one. +public type Tweet_geo record { + Point coordinates?; + PlaceId place_id?; +}; + +public type CreateMessageRequest CreateTextMessageRequest|CreateAttachmentsMessageRequest; + +# Status of a compliance job. +public type ComplianceJobStatus "created"|"in_progress"|"failed"|"complete"|"expired"; + +# Poll options for a Tweet with a poll. This is mutually exclusive from Media, Quote Tweet Id, and Card URI. +public type TweetCreateRequest_poll record {| + # Duration of the poll in minutes. + @constraint:Int {minValue: 5, maxValue: 10080} + int:Signed32 duration_minutes; + @constraint:Array {maxLength: 4, minLength: 2} + TweetCreateRequest_pollOptionsItemsString[] options; + # Settings to indicate who can reply to the Tweet. + "following"|"mentionedUsers" reply_settings?; +|}; + +public type TweetCreateResponse record { + TweetCreateResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# The height of the media in pixels. +@constraint:Int {minValue: 0} +public type MediaHeight int; + +public type TweetUndropComplianceSchema record { + TweetComplianceSchema undrop; +}; + +public type Get2UsersIdResponse record { + User data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +# Represents the Queries record for the operation: getLikesComplianceStream +public type GetLikesComplianceStreamQueries record { + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Likes Compliance events will be provided. + string start_time?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Likes Compliance events will be provided. + string end_time?; +}; + +# The X User object. +public type User record { + # Returns detailed information about the relationship between two users. + ("follow_request_received"|"follow_request_sent"|"blocking"|"followed_by"|"following"|"muting")[] connection_status?; + # Creation time of this User. + string created_at?; + # The text of this User's profile description (also known as bio), if the User provided one. + string description?; + User_entities entities?; + UserId id; + # The location specified in the User's profile, if the User provided one. As this is a freeform value, it may not indicate a valid location, but it may be fuzzily evaluated when performing searches with location queries. + string location?; + TweetId most_recent_tweet_id?; + # The friendly name of this User, as shown on their profile. + string name; + TweetId pinned_tweet_id?; + # The URL to the profile image for this User. + string profile_image_url?; + # Indicates if this User has chosen to protect their Posts (in other words, if this User's Posts are private). + boolean protected?; + User_public_metrics public_metrics?; + # Indicates if you can send a DM to this User + boolean receives_your_dm?; + # The X Blue subscription type of the user, eg: Basic, Premium, PremiumPlus or None. + "Basic"|"Premium"|"PremiumPlus"|"None" subscription_type?; + # The URL specified in the User's profile. + string url?; + UserName username; + # Indicate if this User is a verified X User. + boolean verified?; + # The X Blue verified type of the user, eg: blue, government, business or none. + "blue"|"government"|"business"|"none" verified_type?; + UserWithheld withheld?; +}; + +# Tweet label stream events. +public type TweetLabelStreamResponse record {TweetLabelData data;}|record {Problem[] errors;}; + +# Represents the Queries record for the operation: tweetsFullarchiveSearch +public type TweetsFullarchiveSearchQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length. + @constraint:String {maxLength: 4096, minLength: 1} + string query; + # YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute). + string end_time?; + # Returns results with a Post ID greater than (that is, more recent than) the specified ID. + TweetId since_id?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 next_token?; + # YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute). + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified. + PaginationToken36 pagination_token?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of search results to be returned by a request. + @constraint:Int {minValue: 10, maxValue: 500} + int:Signed32 max_results = 10; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; + # This order in which to return results. + "recency"|"relevancy" sort_order?; + # Returns results with a Post ID less than (that is, older than) the specified ID. + TweetId until_id?; +}; + +# A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched. +public type FilteredStreamingTweetResponse record { + Tweet data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + # The list of rules which matched the Tweet + FilteredStreamingTweetResponse_matching_rules[] matching_rules?; +}; + +# The next token. +@constraint:String {minLength: 1} +public type NextToken string; + +# Unique identifier of this rule. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type RuleId string; + +public type UsersRetweetsCreateResponse_data record { + TweetId id?; + boolean retweeted?; +}; + +public type UserTakedownComplianceSchema record { + # Event time. + string event_at; + UserComplianceSchema_user user; + @constraint:Array {minLength: 1} + CountryCode[] withheld_in_countries; +}; + +public type Get2UsersIdMutingResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# The Media Key identifier for this attachment. +@constraint:String {pattern: re `^([0-9]+)_([0-9]+)$`} +public type MediaKey string; + +# Represents the Queries record for the operation: usersIdFollowing +public type UsersIdFollowingQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + +# The unique identifier of this List. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type ListId string; + +public type Get2DmConversationsIdDmEventsResponse record { + @constraint:Array {minLength: 1} + DmEvent[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +# Represents the Queries record for the operation: getTweetsFirehoseStream +public type GetTweetsFirehoseStreamQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # The number of minutes of backfill requested. + @constraint:Int {minValue: 0, maxValue: 5} + int:Signed32 backfill_minutes?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # The partition number. + @constraint:Int {minValue: 1, maxValue: 20} + int:Signed32 partition; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. + string end_time?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +# Represents the Queries record for the operation: getUsersIdBookmarks +public type GetUsersIdBookmarksQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; +}; + +public type UserUnsuspendComplianceSchema record { + UserComplianceSchema user_unsuspend; +}; + +# Unique identifier of this Topic. +public type TopicId string; + +public type TweetEditComplianceSchema record { + TweetEditComplianceObjectSchema tweet_edit; +}; + +# A two-letter ISO 3166-1 alpha-2 country code. +@constraint:String {pattern: re `^[A-Z]{2}$`} +public type CountryCode string; + +# The topic of a Space, as selected by its creator. +public type Topic record { + # The description of the given topic. + string description?; + TopicId id; + # The name of the given topic. + string name; +}; + +# Compliance Job ID. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type JobId string; + +public type TweetUnviewable record { + # If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’. + string application; + # Event time. + string event_at; + TweetComplianceSchema_tweet tweet; +}; + +public type UserProfileModificationComplianceSchema record { + UserProfileModificationObjectSchema user_profile_modification; +}; + +public type MentionEntity record { + *EntityIndicesInclusiveExclusive; + *MentionFields; +}; + +public type Get2UsersIdPinnedListsResponse record { + @constraint:Array {minLength: 1} + List[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2ComplianceJobsResponse_meta meta?; +}; + +public type Get2TweetsCountsAllResponse_meta record { + NewestId newest_id?; + NextToken next_token?; + OldestId oldest_id?; + Aggregate total_tweet_count?; +}; + +public type UsersLikesCreateRequest record { + TweetId tweet_id; +}; + +# Represents the Queries record for the operation: usersIdTweets +public type UsersIdTweetsQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified. + string end_time?; + # The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified. + TweetId since_id?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 5, maxValue: 100} + int:Signed32 max_results?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # The set of entities to exclude (e.g. 'replies' or 'retweets'). + @constraint:Array {minLength: 1} + ("replies"|"retweets")[] exclude?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; + # The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified. + TweetId until_id?; +}; + +public type ListDeleteResponse record { + DeleteDmResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# The unique identifier of this Space. +@constraint:String {pattern: re `^[a-zA-Z0-9]{1,13}$`} +public type SpaceId string; + +public type TweetDeleteResponse record { + TweetDeleteResponse_data data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + +# Expiration time of the upload URL. +public type UploadExpiration string; + +# A [GeoJson Point](https://tools.ietf.org/html/rfc7946#section-3.1.2) geometry object. +public type Point record { + Position coordinates; + "Point" 'type; +}; + +# Proxy server configurations to be used with the HTTP client endpoint. +public type ProxyConfig record {| + # Host name of the proxy server + string host = ""; + # Proxy server port + int port = 0; + # Proxy server username + string userName = ""; + # Proxy server password + @display {label: "", kind: "password"} + string password = ""; +|}; + +public type Get2UsersIdMentionsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2UsersIdMentionsResponse_meta meta?; +}; + +public type Get2ListsIdTweetsResponse record { + @constraint:Array {minLength: 1} + Tweet[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + Get2DmConversationsIdDmEventsResponse_meta meta?; +}; + +public type Get2ComplianceJobsResponse_meta record { + ResultCount result_count?; +}; + +public type ListCreateRequest record { + @constraint:String {maxLength: 100} + string description?; + @constraint:String {maxLength: 25, minLength: 1} + string name; + boolean 'private = false; +}; + +public type Get2UsersSearchResponse_meta record { + NextToken next_token?; + PreviousToken previous_token?; +}; + +# Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type UserId string; + +# Represent a Poll attached to a Tweet. +public type Poll record { + @constraint:Int {minValue: 5, maxValue: 10080} + int:Signed32 duration_minutes?; + string end_datetime?; + PollId id; + @constraint:Array {maxLength: 4, minLength: 2} + PollOption[] options; + "open"|"closed" voting_status?; +}; + +# Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country). +public type UserWithheld record { + # Provides a list of countries where this content is not available. + @constraint:Array {minLength: 1} + CountryCode[] country_codes; + # Indicates that the content being withheld is a `user`. + "user" scope?; +}; + +# Represents the Queries record for the operation: usersIdTimeline +public type UsersIdTimelineQueries record { + # A comma separated list of Poll fields to display. + ("duration_minutes"|"end_datetime"|"id"|"options"|"voting_status")[] poll\.fields?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified. + string end_time?; + # The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified. + TweetId since_id?; + # YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified. + string start_time?; + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get the next 'page' of results. + PaginationToken36 pagination_token?; + # A comma separated list of Media fields to display. + ("alt_text"|"duration_ms"|"height"|"media_key"|"non_public_metrics"|"organic_metrics"|"preview_image_url"|"promoted_metrics"|"public_metrics"|"type"|"url"|"variants"|"width")[] media\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 100} + int:Signed32 max_results?; + # A comma separated list of Place fields to display. + ("contained_within"|"country"|"country_code"|"full_name"|"geo"|"id"|"name"|"place_type")[] place\.fields?; + # The set of entities to exclude (e.g. 'replies' or 'retweets'). + ("replies"|"retweets")[] exclude?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; + # The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified. + TweetId until_id?; +}; + +public type Get2DmEventsEventIdResponse record { + DmEvent data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + +public type Get2UsersResponse record { + @constraint:Array {minLength: 1} + User[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; diff --git a/ballerina/utils.bal b/ballerina/utils.bal new file mode 100644 index 0000000..8fb8e44 --- /dev/null +++ b/ballerina/utils.bal @@ -0,0 +1,201 @@ +// AUTO-GENERATED FILE. DO NOT MODIFY. +// This file is auto-generated by the Ballerina OpenAPI tool. + +import ballerina/url; + +type SimpleBasicType string|boolean|int|float|decimal; + +# Represents encoding mechanism details. +type Encoding record { + # Defines how multiple values are delimited + string style = FORM; + # Specifies whether arrays and objects should generate as separate fields + boolean explode = true; + # Specifies the custom content type + string contentType?; + # Specifies the custom headers + map headers?; +}; + +enum EncodingStyle { + DEEPOBJECT, FORM, SPACEDELIMITED, PIPEDELIMITED +} + +final Encoding & readonly defaultEncoding = {}; + +# Serialize the record according to the deepObject style. +# +# + parent - Parent record name +# + anyRecord - Record to be serialized +# + return - Serialized record as a string +isolated function getDeepObjectStyleRequest(string parent, record {} anyRecord) returns string { + string[] recordArray = []; + foreach [string, anydata] [key, value] in anyRecord.entries() { + if value is SimpleBasicType { + recordArray.push(parent + "[" + key + "]" + "=" + getEncodedUri(value.toString())); + } else if value is SimpleBasicType[] { + recordArray.push(getSerializedArray(parent + "[" + key + "]" + "[]", value, DEEPOBJECT, true)); + } else if value is record {} { + string nextParent = parent + "[" + key + "]"; + recordArray.push(getDeepObjectStyleRequest(nextParent, value)); + } else if value is record {}[] { + string nextParent = parent + "[" + key + "]"; + recordArray.push(getSerializedRecordArray(nextParent, value, DEEPOBJECT)); + } + recordArray.push("&"); + } + _ = recordArray.pop(); + return string:'join("", ...recordArray); +} + +# Serialize the record according to the form style. +# +# + parent - Parent record name +# + anyRecord - Record to be serialized +# + explode - Specifies whether arrays and objects should generate separate parameters +# + return - Serialized record as a string +isolated function getFormStyleRequest(string parent, record {} anyRecord, boolean explode = true) returns string { + string[] recordArray = []; + if explode { + foreach [string, anydata] [key, value] in anyRecord.entries() { + if value is SimpleBasicType { + recordArray.push(key, "=", getEncodedUri(value.toString())); + } else if value is SimpleBasicType[] { + recordArray.push(getSerializedArray(key, value, explode = explode)); + } else if value is record {} { + recordArray.push(getFormStyleRequest(parent, value, explode)); + } + recordArray.push("&"); + } + _ = recordArray.pop(); + } else { + foreach [string, anydata] [key, value] in anyRecord.entries() { + if value is SimpleBasicType { + recordArray.push(key, ",", getEncodedUri(value.toString())); + } else if value is SimpleBasicType[] { + recordArray.push(getSerializedArray(key, value, explode = false)); + } else if value is record {} { + recordArray.push(getFormStyleRequest(parent, value, explode)); + } + recordArray.push(","); + } + _ = recordArray.pop(); + } + return string:'join("", ...recordArray); +} + +# Serialize arrays. +# +# + arrayName - Name of the field with arrays +# + anyArray - Array to be serialized +# + style - Defines how multiple values are delimited +# + explode - Specifies whether arrays and objects should generate separate parameters +# + return - Serialized array as a string +isolated function getSerializedArray(string arrayName, anydata[] anyArray, string style = "form", boolean explode = true) returns string { + string key = arrayName; + string[] arrayValues = []; + if anyArray.length() > 0 { + if style == FORM && !explode { + arrayValues.push(key, "="); + foreach anydata i in anyArray { + arrayValues.push(getEncodedUri(i.toString()), ","); + } + } else if style == SPACEDELIMITED && !explode { + arrayValues.push(key, "="); + foreach anydata i in anyArray { + arrayValues.push(getEncodedUri(i.toString()), "%20"); + } + } else if style == PIPEDELIMITED && !explode { + arrayValues.push(key, "="); + foreach anydata i in anyArray { + arrayValues.push(getEncodedUri(i.toString()), "|"); + } + } else if style == DEEPOBJECT { + foreach anydata i in anyArray { + arrayValues.push(key, "[]", "=", getEncodedUri(i.toString()), "&"); + } + } else { + foreach anydata i in anyArray { + arrayValues.push(key, "=", getEncodedUri(i.toString()), "&"); + } + } + _ = arrayValues.pop(); + } + return string:'join("", ...arrayValues); +} + +# Serialize the array of records according to the form style. +# +# + parent - Parent record name +# + value - Array of records to be serialized +# + style - Defines how multiple values are delimited +# + explode - Specifies whether arrays and objects should generate separate parameters +# + return - Serialized record as a string +isolated function getSerializedRecordArray(string parent, record {}[] value, string style = FORM, boolean explode = true) returns string { + string[] serializedArray = []; + if style == DEEPOBJECT { + int arayIndex = 0; + foreach var recordItem in value { + serializedArray.push(getDeepObjectStyleRequest(parent + "[" + arayIndex.toString() + "]", recordItem), "&"); + arayIndex = arayIndex + 1; + } + } else { + if !explode { + serializedArray.push(parent, "="); + } + foreach var recordItem in value { + serializedArray.push(getFormStyleRequest(parent, recordItem, explode), ","); + } + } + _ = serializedArray.pop(); + return string:'join("", ...serializedArray); +} + +# Get Encoded URI for a given value. +# +# + value - Value to be encoded +# + return - Encoded string +isolated function getEncodedUri(anydata value) returns string { + string|error encoded = url:encode(value.toString(), "UTF8"); + if encoded is string { + return encoded; + } else { + return value.toString(); + } +} + +# Generate query path with query parameter. +# +# + queryParam - Query parameter map +# + encodingMap - Details on serialization mechanism +# + return - Returns generated Path or error at failure of client initialization +isolated function getPathForQueryParam(map queryParam, map encodingMap = {}) returns string|error { + string[] param = []; + if queryParam.length() > 0 { + param.push("?"); + foreach var [key, value] in queryParam.entries() { + if value is () { + _ = queryParam.remove(key); + continue; + } + Encoding encodingData = encodingMap.hasKey(key) ? encodingMap.get(key) : defaultEncoding; + if value is SimpleBasicType { + param.push(key, "=", getEncodedUri(value.toString())); + } else if value is SimpleBasicType[] { + param.push(getSerializedArray(key, value, encodingData.style, encodingData.explode)); + } else if value is record {} { + if encodingData.style == DEEPOBJECT { + param.push(getDeepObjectStyleRequest(key, value)); + } else { + param.push(getFormStyleRequest(key, value, encodingData.explode)); + } + } else { + param.push(key, "=", value.toString()); + } + param.push("&"); + } + _ = param.pop(); + } + string restOfPath = string:'join("", ...param); + return restOfPath; +} diff --git a/docs/twitter_open_api_spec.json b/docs/twitter_open_api_spec.json new file mode 100644 index 0000000..8ec6719 --- /dev/null +++ b/docs/twitter_open_api_spec.json @@ -0,0 +1,15432 @@ +{ + "openapi" : "3.0.0", + "info" : { + "description" : "Twitter API v2 available endpoints", + "version" : "2.100", + "title" : "Twitter API v2", + "termsOfService" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html", + "contact" : { + "name" : "Twitter Developers", + "url" : "https://developer.twitter.com/" + }, + "license" : { + "name" : "Twitter Developer Agreement and Policy", + "url" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html" + } + }, + "paths" : { + "/2/compliance/jobs" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "List Compliance Jobs", + "description" : "Returns recent Compliance Jobs for a given job type and optional job status", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs" + }, + "operationId" : "listBatchComplianceJobs", + "parameters" : [ + { + "name" : "type", + "in" : "query", + "description" : "Type of Compliance Job to list.", + "required" : true, + "schema" : { + "type" : "string", + "enum" : [ + "tweets", + "users" + ] + }, + "style" : "form" + }, + { + "name" : "status", + "in" : "query", + "description" : "Status of Compliance Job to list.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "created", + "in_progress", + "failed", + "complete" + ] + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ComplianceJobsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Create compliance job", + "description" : "Creates a compliance for the given job type", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/post-compliance-jobs" + }, + "operationId" : "createBatchComplianceJob", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateComplianceJobRequest" + } + } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateComplianceJobResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/compliance/jobs/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Get Compliance Job", + "description" : "Returns a single Compliance Job by ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs-id" + }, + "operationId" : "getBatchComplianceJob", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Compliance Job to retrieve.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/JobId" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ComplianceJobsIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_conversations" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Create a new DM Conversation", + "description" : "Creates a new DM Conversation.", + "operationId" : "dmConversationIdCreate", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateDmConversationRequest" + } + } + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateDmEventResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_conversations/with/{participant_id}/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events for a DM Conversation", + "description" : "Returns DM Events for a DM Conversation", + "operationId" : "getDmConversationsWithParticipantIdDmEvents", + "parameters" : [ + { + "name" : "participant_id", + "in" : "path", + "description" : "The ID of the participant user for the One to One DM conversation.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "MessageCreate", + "ParticipantsJoin", + "ParticipantsLeave" + ] + }, + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmConversationsWithParticipantIdDmEventsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_conversations/with/{participant_id}/messages" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Send a new message to a user", + "description" : "Creates a new message for a DM Conversation with a participant user by ID", + "operationId" : "dmConversationWithUserEventIdCreate", + "parameters" : [ + { + "name" : "participant_id", + "in" : "path", + "description" : "The ID of the recipient user that will receive the DM.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateMessageRequest" + } + } + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateDmEventResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_conversations/{dm_conversation_id}/messages" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Send a new message to a DM Conversation", + "description" : "Creates a new message for a DM Conversation specified by DM Conversation ID", + "operationId" : "dmConversationByIdEventIdCreate", + "parameters" : [ + { + "name" : "dm_conversation_id", + "in" : "path", + "description" : "The DM Conversation ID.", + "required" : true, + "schema" : { + "type" : "string" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateMessageRequest" + } + } + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateDmEventResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_conversations/{id}/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events for a DM Conversation", + "description" : "Returns DM Events for a DM Conversation", + "operationId" : "getDmConversationsIdDmEvents", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The DM Conversation ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmConversationId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "MessageCreate", + "ParticipantsJoin", + "ParticipantsLeave" + ] + }, + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmConversationsIdDmEventsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get recent DM Events", + "description" : "Returns recent DM Events across DM conversations", + "operationId" : "getDmEvents", + "parameters" : [ + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "MessageCreate", + "ParticipantsJoin", + "ParticipantsLeave" + ] + }, + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmEventsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/dm_events/{event_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "dm.write" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Delete Dm", + "description" : "Delete a Dm Event that you own.", + "operationId" : "dmEventDelete", + "parameters" : [ + { + "name" : "event_id", + "in" : "path", + "description" : "The ID of the direct-message event to delete.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmEventId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/DeleteDmResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events by id", + "description" : "Returns DM Events by event id.", + "operationId" : "getDmEventsById", + "parameters" : [ + { + "name" : "event_id", + "in" : "path", + "description" : "dm event id.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmEventId" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmEventsEventIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/likes/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Likes Compliance stream", + "description" : "Streams 100% of compliance data for Users", + "operationId" : "getLikesComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Likes Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Likes Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/LikesComplianceStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/likes/firehose/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Likes" + ], + "summary" : "Likes Firehose stream", + "description" : "Streams 100% of public Likes.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-likes-firehose-stream" + }, + "operationId" : "likesFirehoseStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 20, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/LikeFieldsParameter" + }, + { + "$ref" : "#/components/parameters/LikeExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingLikeResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/likes/sample10/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Likes" + ], + "summary" : "Likes Sample 10 stream", + "description" : "Streams 10% of public Likes.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/likes/firehose/api-reference/get-likes-sample10-stream" + }, + "operationId" : "likesSample10Stream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/LikeFieldsParameter" + }, + { + "$ref" : "#/components/parameters/LikeExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingLikeResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/lists" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.read", + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Create List", + "description" : "Creates a new List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/post-lists" + }, + "operationId" : "listIdCreate", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListCreateRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListCreateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/lists/{id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Delete List", + "description" : "Delete a List that you own.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/delete-lists-id" + }, + "operationId" : "listIdDelete", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to delete.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "List lookup by List ID.", + "description" : "Returns a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-lists-id" + }, + "operationId" : "listIdGet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "put" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Update List.", + "description" : "Update a List that you own.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/put-lists-id" + }, + "operationId" : "listIdUpdate", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to modify.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListUpdateRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListUpdateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/lists/{id}/followers" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that follow a List by the provided List ID", + "description" : "Returns a list of Users that follow a List by the provided List ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" + }, + "operationId" : "listGetFollowers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdFollowersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/lists/{id}/members" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are members of a List by the provided List ID.", + "description" : "Returns a list of Users that are members of a List by the provided List ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" + }, + "operationId" : "listGetMembers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdMembersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Add a List member", + "description" : "Causes a User to become a member of a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/post-lists-id-members" + }, + "operationId" : "listAddMember", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List for which to add a member.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListAddUserRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListMutateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/lists/{id}/members/{user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Remove a List member", + "description" : "Causes a User to be removed from the members of a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/delete-lists-id-members-user_id" + }, + "operationId" : "listRemoveMember", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to remove a member.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + }, + { + "name" : "user_id", + "in" : "path", + "description" : "The ID of User that will be removed from the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListMutateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/lists/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "List Posts timeline by List ID.", + "description" : "Returns a list of Posts associated with the provided List ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-tweets/api-reference/get-lists-id-tweets" + }, + "operationId" : "listsIdTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/openapi.json" : { + "get" : { + "tags" : [ + "General" + ], + "summary" : "Returns the OpenAPI Specification document.", + "description" : "Full OpenAPI Specification in JSON format. (See https://github.com/OAI/OpenAPI-Specification/blob/master/README.md)", + "operationId" : "getOpenApiSpec", + "parameters" : [ ], + "responses" : { + "200" : { + "description" : "The request was successful", + "content" : { + "application/json" : { + "schema" : { + "type" : "object" + } + } + } + } + } + } + }, + "/2/spaces" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup up Space IDs", + "description" : "Returns a variety of information about the Spaces specified by the requested IDs", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces" + }, + "operationId" : "findSpacesByIds", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "The list of Space IDs to return.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + } + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/spaces/by/creator_ids" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup by their creators", + "description" : "Returns a variety of information about the Spaces created by the provided User IDs", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-by-creator-ids" + }, + "operationId" : "findSpacesByCreatorIds", + "parameters" : [ + { + "name" : "user_ids", + "in" : "query", + "description" : "The IDs of Users to search through.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesByCreatorIdsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/spaces/search" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Search for Spaces", + "description" : "Returns Spaces that match the provided query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/search/api-reference/get-spaces-search" + }, + "operationId" : "searchSpaces", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "The search query.", + "required" : true, + "example" : "crypto", + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 2048, + "example" : "crypto" + }, + "style" : "form" + }, + { + "name" : "state", + "in" : "query", + "description" : "The state of Spaces to search for.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "live", + "scheduled", + "all" + ], + "default" : "all" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The number of results to return.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesSearchResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/spaces/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup by Space ID", + "description" : "Returns a variety of information about the Space specified by the requested ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id" + }, + "operationId" : "findSpaceById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/spaces/{id}/buyers" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces", + "Tweets" + ], + "summary" : "Retrieve the list of Users who purchased a ticket to the given space", + "description" : "Retrieves the list of Users who purchased a ticket to the given space", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-buyers" + }, + "operationId" : "spaceBuyers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "style" : "simple" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesIdBuyersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/spaces/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces", + "Tweets" + ], + "summary" : "Retrieve Posts from a Space.", + "description" : "Retrieves Posts shared in the specified Space.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-tweets" + }, + "operationId" : "spaceTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The number of Posts to fetch from the provided space. If not provided, the value will default to the maximum of 100.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100, + "example" : 25 + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesIdTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/trends/by/woeid/{woeid}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Trends" + ], + "summary" : "Trends", + "description" : "Returns the Trend associated with the supplied WoeId.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/trends/api-reference/get-trends-by-woeid" + }, + "operationId" : "getTrends", + "parameters" : [ + { + "name" : "woeid", + "in" : "path", + "description" : "The WOEID of the place to lookup a trend for.", + "required" : true, + "example" : "2244994945", + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/TrendFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TrendsByWoeidWoeidResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post lookup by Post IDs", + "description" : "Returns a variety of information about the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets" + }, + "operationId" : "findTweetsById", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A comma separated list of Post IDs. Up to 100 are allowed in a single request.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Creation of a Post", + "description" : "Causes the User to create a Post under the authorized account.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/post-tweets" + }, + "operationId" : "createTweet", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetCreateRequest" + } + } + }, + "required" : true + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetCreateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Posts Compliance stream", + "description" : "Streams 100% of compliance data for Posts", + "operationId" : "getTweetsComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 4, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Post Compliance events will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetComplianceStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/counts/all" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Full archive search counts", + "description" : "Returns Post Counts that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" + }, + "operationId" : "tweetCountsFullArchiveSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "granularity", + "in" : "query", + "description" : "The granularity for the search counts results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "minute", + "hour", + "day" + ], + "default" : "hour" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SearchCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsCountsAllResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/counts/recent" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Recent search counts", + "description" : "Returns Post Counts from the last 7 days that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/counts/api-reference/get-tweets-counts-recent" + }, + "operationId" : "tweetCountsRecentSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "granularity", + "in" : "query", + "description" : "The granularity for the search counts results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "minute", + "hour", + "day" + ], + "default" : "hour" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SearchCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsCountsRecentResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/firehose/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Firehose stream", + "description" : "Streams 100% of public Posts.", + "operationId" : "getTweetsFirehoseStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 20, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/firehose/stream/lang/en" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "English Language Firehose stream", + "description" : "Streams 100% of English Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangEn", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 8, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/firehose/stream/lang/ja" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Japanese Language Firehose stream", + "description" : "Streams 100% of Japanese Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangJa", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/firehose/stream/lang/ko" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Korean Language Firehose stream", + "description" : "Streams 100% of Korean Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangKo", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/firehose/stream/lang/pt" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Portuguese Language Firehose stream", + "description" : "Streams 100% of Portuguese Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangPt", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/label/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Posts Label stream", + "description" : "Streams 100% of labeling events applied to Posts", + "operationId" : "getTweetsLabelStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post labels will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Post labels will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetLabelStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/sample/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Sample stream", + "description" : "Streams a deterministic 1% of public Posts.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/volume-streams/api-reference/get-tweets-sample-stream" + }, + "operationId" : "sampleStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/sample10/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Sample 10% stream", + "description" : "Streams a deterministic 10% of public Posts.", + "operationId" : "getTweetsSample10Stream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSample10StreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/search/all" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Full-archive search", + "description" : "Returns Posts that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" + }, + "operationId" : "tweetsFullarchiveSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of search results to be returned by a request.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 500, + "format" : "int32", + "default" : 10 + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "sort_order", + "in" : "query", + "description" : "This order in which to return results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "recency", + "relevancy" + ] + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchAllResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/search/recent" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Recent search", + "description" : "Returns Posts from the last 7 days that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-recent" + }, + "operationId" : "tweetsRecentSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of search results to be returned by a request.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 100, + "format" : "int32", + "default" : 10 + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "sort_order", + "in" : "query", + "description" : "This order in which to return results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "recency", + "relevancy" + ] + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchRecentResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/search/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Filtered stream", + "description" : "Streams Posts matching the stream's active rule set.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream" + }, + "operationId" : "searchStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/FilteredStreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/tweets/search/stream/rules" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Rules lookup", + "description" : "Returns rules from a User's active rule set. Users can fetch all of their rules or a subset, specified by the provided rule ids.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules" + }, + "operationId" : "getRules", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A comma-separated list of Rule IDs.", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/RuleId" + } + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 1000 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This value is populated by passing the 'next_token' returned in a request to paginate through results.", + "required" : false, + "schema" : { + "type" : "string", + "minLength" : 16, + "maxLength" : 16 + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/RulesLookupResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Add/Delete rules", + "description" : "Add or delete rules from a User's active rule set. Users can provide unique, optionally tagged rules to add. Users can delete their entire rule set or a subset specified by rule ids or values.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/post-tweets-search-stream-rules" + }, + "operationId" : "addOrDeleteRules", + "parameters" : [ + { + "name" : "dry_run", + "in" : "query", + "description" : "Dry Run can be used with both the add and delete action, with the expected result given, but without actually taking any action in the system (meaning the end state will always be as it was when the request was submitted). This is particularly useful to validate rule changes.", + "required" : false, + "schema" : { + "type" : "boolean" + }, + "style" : "form" + }, + { + "name" : "delete_all", + "in" : "query", + "description" : "Delete All can be used to delete all of the rules associated this client app, it should be specified with no other parameters. Once deleted, rules cannot be recovered.", + "required" : false, + "schema" : { + "type" : "boolean" + }, + "style" : "form" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/AddOrDeleteRulesRequest" + } + } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/AddOrDeleteRulesResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/search/stream/rules/counts" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "General" + ], + "summary" : "Rules Count", + "description" : "Returns the counts of rules from a User's active rule set, to reflect usage by project and application.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules-counts" + }, + "operationId" : "getRuleCount", + "parameters" : [ + { + "$ref" : "#/components/parameters/RulesCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchStreamRulesCountsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post delete by Post ID", + "description" : "Delete specified Post (in the path) by ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/delete-tweets-id" + }, + "operationId" : "deleteTweetById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Post to be deleted.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post lookup by Post ID", + "description" : "Returns a variety of information about the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets-id" + }, + "operationId" : "findTweetById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{id}/liking_users" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that have liked the provided Post ID", + "description" : "Returns a list of Users that have liked the provided Post ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-tweets-id-liking_users" + }, + "operationId" : "tweetsIdLikingUsers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdLikingUsersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{id}/quote_tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Retrieve Posts that quote a Post.", + "description" : "Returns a variety of information about each Post that quotes the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/quote-tweets/api-reference/get-tweets-id-quote_tweets" + }, + "operationId" : "findTweetsThatQuoteATweet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results to be returned.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 100, + "format" : "int32", + "default" : 10 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "replies", + "retweets" + ] + }, + "example" : [ + "replies", + "retweets" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdQuoteTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{id}/retweeted_by" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that have retweeted the provided Post ID", + "description" : "Returns a list of Users that have retweeted the provided Post ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweeted_by" + }, + "operationId" : "tweetsIdRetweetingUsers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdRetweetedByResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{id}/retweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Retrieve Posts that repost a Post.", + "description" : "Returns a variety of information about each Post that has retweeted the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweets" + }, + "operationId" : "findTweetsThatRetweetATweet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdRetweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/tweets/{tweet_id}/hidden" : { + "put" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.moderate.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Hide replies", + "description" : "Hides or unhides a reply to an owned conversation.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/hide-replies/api-reference/put-tweets-id-hidden" + }, + "operationId" : "hideReplyById", + "parameters" : [ + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the reply that you want to hide or unhide.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetHideRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetHideResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/usage/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Usage" + ], + "summary" : "Post Usage", + "description" : "Returns the Post Usage.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/usage/tweets/api-reference/get-usage-tweets" + }, + "operationId" : "getUsageTweets", + "parameters" : [ + { + "name" : "days", + "in" : "query", + "description" : "The number of days for which you need usage for.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 90, + "format" : "int32", + "default" : 7 + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UsageFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsageTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by IDs", + "description" : "This endpoint returns information about Users. Specify Users by their ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users" + }, + "operationId" : "findUsersById", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A list of User IDs, comma-separated. You can specify up to 100 IDs.", + "required" : true, + "example" : "2244994945,6253282,12", + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/by" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by usernames", + "description" : "This endpoint returns information about Users. Specify Users by their username.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by" + }, + "operationId" : "findUsersByUsername", + "parameters" : [ + { + "name" : "usernames", + "in" : "query", + "description" : "A list of usernames, comma-separated.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "type" : "string", + "description" : "The X handle (screen name) of this User.", + "pattern" : "^[A-Za-z0-9_]{1,15}$" + }, + "example" : "TwitterDev,TwitterAPI" + }, + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersByResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/by/username/{username}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by username", + "description" : "This endpoint returns information about a User. Specify User by username.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by-username-username" + }, + "operationId" : "findUserByUsername", + "parameters" : [ + { + "name" : "username", + "in" : "path", + "description" : "A username.", + "required" : true, + "example" : "TwitterDev", + "schema" : { + "type" : "string", + "pattern" : "^[A-Za-z0-9_]{1,15}$" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersByUsernameUsernameResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Users Compliance stream", + "description" : "Streams 100% of compliance data for Users", + "operationId" : "getUsersComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 4, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the User Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the User Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UserComplianceStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/2/users/me" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup me", + "description" : "This endpoint returns information about the requesting User.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-me" + }, + "operationId" : "findMyUser", + "parameters" : [ + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersMeResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/search" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User search", + "description" : "Returns Users that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-search" + }, + "operationId" : "searchUserByQuery", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "TThe the query string by which to query for users.", + "required" : true, + "example" : "someXUser", + "schema" : { + "$ref" : "#/components/schemas/UserSearchQuery" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersSearchResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by ID", + "description" : "This endpoint returns information about a User. Specify User by ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-id" + }, + "operationId" : "findUserById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/blocking" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "block.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are blocked by provided User ID", + "description" : "Returns a list of Users that are blocked by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/blocks/api-reference/get-users-blocking" + }, + "operationId" : "usersIdBlocking", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdBlockingResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/bookmarks" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Bookmarks by User", + "description" : "Returns Post objects that have been bookmarked by the requesting User", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/get-users-id-bookmarks" + }, + "operationId" : "getUsersIdBookmarks", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdBookmarksResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.write", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Add Post to Bookmarks", + "description" : "Adds a Post (ID in the body) to the requesting User's (in the path) bookmarks", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/post-users-id-bookmarks" + }, + "operationId" : "postUsersIdBookmarks", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to add bookmarks.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/BookmarkAddRequest" + } + } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/BookmarkMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/bookmarks/{tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.write", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Remove a bookmarked Post", + "description" : "Removes a Post from the requesting User's bookmarked Posts.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/delete-users-id-bookmarks-tweet_id" + }, + "operationId" : "usersIdBookmarksDelete", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User whose bookmark is to be removed.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the Post that the source User is removing from bookmarks.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/BookmarkMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/followed_lists" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get User's Followed Lists", + "description" : "Returns a User's followed Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/get-users-id-followed_lists" + }, + "operationId" : "userFollowedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowedListsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Follow a List", + "description" : "Causes a User to follow a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/post-users-id-followed-lists" + }, + "operationId" : "listUserFollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will follow the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListFollowedRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListFollowedResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/followed_lists/{list_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Unfollow a List", + "description" : "Causes a User to unfollow a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/delete-users-id-followed-lists-list_id" + }, + "operationId" : "listUserUnfollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will unfollow the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "list_id", + "in" : "path", + "description" : "The ID of the List to unfollow.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListFollowedResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/followers" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "follows.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Followers by User ID", + "description" : "Returns a list of Users who are followers of the specified User ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" + }, + "operationId" : "usersIdFollowers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowersResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/following" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "follows.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Following by User ID", + "description" : "Returns a list of Users that are being followed by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-following" + }, + "operationId" : "usersIdFollowing", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowingResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "follows.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Follow User", + "description" : "Causes the User(in the path) to follow, or “request to follow” for protected Users, the target User. The User(in the path) must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/post-users-source_user_id-following" + }, + "operationId" : "usersIdFollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to follow the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersFollowingCreateRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersFollowingCreateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/liked_tweets" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Returns Post objects liked by the provided User ID", + "description" : "Returns a list of Posts liked by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-users-id-liked_tweets" + }, + "operationId" : "usersIdLikedTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdLikedTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/likes" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to like the specified Post", + "description" : "Causes the User (in the path) to like the specified Post. The User in the path must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/post-users-id-likes" + }, + "operationId" : "usersIdLike", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to like the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersLikesCreateRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersLikesCreateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/likes/{tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to unlike the specified Post", + "description" : "Causes the User (in the path) to unlike the specified Post. The User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/delete-users-id-likes-tweet_id" + }, + "operationId" : "usersIdUnlike", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unlike the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the Post that the User is requesting to unlike.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersLikesDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/list_memberships" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's List Memberships", + "description" : "Get a User's List Memberships.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" + }, + "operationId" : "getUserListMemberships", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdListMembershipsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/mentions" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User mention timeline by User ID", + "description" : "Returns Post objects that mention username associated to the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-mentions" + }, + "operationId" : "usersIdMentions", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdMentionsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/muting" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are muted by the provided User ID", + "description" : "Returns a list of Users that are muted by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/get-users-muting" + }, + "operationId" : "usersIdMuting", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdMutingResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Mute User by User ID.", + "description" : "Causes the User (in the path) to mute the target User. The User (in the path) must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/post-users-user_id-muting" + }, + "operationId" : "usersIdMute", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to mute the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/MuteUserRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/MuteUserMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/owned_lists" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's Owned Lists.", + "description" : "Get a User's Owned Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-users-id-owned_lists" + }, + "operationId" : "listUserOwnedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdOwnedListsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/pinned_lists" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's Pinned Lists", + "description" : "Get a User's Pinned Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/get-users-id-pinned_lists" + }, + "operationId" : "listUserPinnedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdPinnedListsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Pin a List", + "description" : "Causes a User to pin a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/post-users-id-pinned-lists" + }, + "operationId" : "listUserPin", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will pin the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListPinnedRequest" + } + } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListPinnedResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/pinned_lists/{list_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Unpin a List", + "description" : "Causes a User to remove a pinned List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/delete-users-id-pinned-lists-list_id" + }, + "operationId" : "listUserUnpin", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "list_id", + "in" : "path", + "description" : "The ID of the List to unpin.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListUnpinResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/retweets" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to repost the specified Post.", + "description" : "Causes the User (in the path) to repost the specified Post. The User in the path must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/post-users-id-retweets" + }, + "operationId" : "usersIdRetweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to repost the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersRetweetsCreateRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersRetweetsCreateResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/retweets/{source_tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to unretweet the specified Post", + "description" : "Causes the User (in the path) to unretweet the specified Post. The User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/delete-users-id-retweets-tweet_id" + }, + "operationId" : "usersIdUnretweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to repost the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "source_tweet_id", + "in" : "path", + "description" : "The ID of the Post that the User is requesting to unretweet.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersRetweetsDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/timelines/reverse_chronological" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User home timeline by User ID", + "description" : "Returns Post objects that appears in the provided User ID's home timeline", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-reverse-chronological" + }, + "operationId" : "usersIdTimeline", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User to list Reverse Chronological Timeline Posts of.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "example" : "791775337160081409", + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "replies", + "retweets" + ] + }, + "example" : [ + "replies", + "retweets" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdTimelinesReverseChronologicalResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User Posts timeline by User ID", + "description" : "Returns a list of Posts authored by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-tweets" + }, + "operationId" : "usersIdTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "example" : "791775337160081409", + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "replies", + "retweets" + ] + }, + "example" : [ + "replies", + "retweets" + ] + }, + "explode" : false, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdTweetsResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{source_user_id}/following/{target_user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "follows.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Unfollow User", + "description" : "Causes the source User to unfollow the target User. The source User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/delete-users-source_id-following" + }, + "operationId" : "usersIdUnfollow", + "parameters" : [ + { + "name" : "source_user_id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unfollow the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "target_user_id", + "in" : "path", + "description" : "The ID of the User that the source User is requesting to unfollow.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersFollowingDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/2/users/{source_user_id}/muting/{target_user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Unmute User by User ID", + "description" : "Causes the source User to unmute the target User. The source User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/delete-users-user_id-muting" + }, + "operationId" : "usersIdUnmute", + "parameters" : [ + { + "name" : "source_user_id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unmute the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "target_user_id", + "in" : "path", + "description" : "The ID of the User that the source User is requesting to unmute.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" + }, + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/MuteUserMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + } + }, + "servers" : [ + { + "description" : "Twitter API", + "url" : "https://api.twitter.com" + } + ], + "tags" : [ + { + "name" : "Bookmarks", + "description" : "Endpoints related to retrieving, managing bookmarks of a user", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/bookmarks" + } + }, + { + "name" : "Compliance", + "description" : "Endpoints related to keeping X data in your systems compliant", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-tweet/introduction" + } + }, + { + "name" : "Direct Messages", + "description" : "Endpoints related to retrieving, managing Direct Messages", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/direct-messages" + } + }, + { + "name" : "General", + "description" : "Miscellaneous endpoints for general API functionality", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api" + } + }, + { + "name" : "Lists", + "description" : "Endpoints related to retrieving, managing Lists", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists" + } + }, + { + "name" : "Spaces", + "description" : "Endpoints related to retrieving, managing Spaces", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces" + } + }, + { + "name" : "Tweets", + "description" : "Endpoints related to retrieving, searching, and modifying Tweets", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup" + } + }, + { + "name" : "Users", + "description" : "Endpoints related to retrieving, managing relationships of Users", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup" + } + } + ], + "components" : { + "securitySchemes" : { + "BearerToken" : { + "type" : "http", + "scheme" : "bearer" + }, + "OAuth2UserToken" : { + "type" : "oauth2", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://api.twitter.com/2/oauth2/authorize", + "tokenUrl" : "https://api.twitter.com/2/oauth2/token", + "scopes" : { + "block.read" : "Accounts you’ve blocked.", + "bookmark.read" : "Allows an app to read bookmarked Tweets", + "bookmark.write" : "Allows an app to create and delete bookmarks", + "dm.read" : "All your Direct Messages", + "dm.write" : "Send and manage Direct Messages for you", + "follows.read" : "People who follow you and people who you follow.", + "follows.write" : "Follow and unfollow people for you.", + "like.read" : "Tweets you’ve liked and likes you can view.", + "like.write" : "Like and un-like Tweets for you.", + "list.read" : "Lists, list members, and list followers of lists you’ve created or are a member of, including private lists.", + "list.write" : "Create and manage Lists for you.", + "mute.read" : "Accounts you’ve muted.", + "mute.write" : "Mute and unmute accounts for you.", + "offline.access" : "App can request refresh token.", + "space.read" : "Access all of the Spaces you can see.", + "tweet.moderate.write" : "Hide and unhide replies to your Tweets.", + "tweet.read" : "All the Tweets you can see, including Tweets from protected accounts.", + "tweet.write" : "Tweet and retweet for you.", + "users.read" : "Any account you can see, including protected accounts. Any account you can see, including protected accounts." + } + } + } + }, + "UserToken" : { + "type" : "http", + "scheme" : "OAuth" + } + }, + "schemas" : { + "AddOrDeleteRulesRequest" : { + "oneOf" : [ + { + "$ref" : "#/components/schemas/AddRulesRequest" + }, + { + "$ref" : "#/components/schemas/DeleteRulesRequest" + } + ] + }, + "AddOrDeleteRulesResponse" : { + "type" : "object", + "description" : "A response from modifying user-specified stream filtering rules.", + "required" : [ + "meta" + ], + "properties" : { + "data" : { + "type" : "array", + "description" : "All user-specified stream filtering rules that were created.", + "items" : { + "$ref" : "#/components/schemas/Rule" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "$ref" : "#/components/schemas/RulesResponseMetadata" + } + } + }, + "AddRulesRequest" : { + "type" : "object", + "description" : "A request to add a user-specified stream filtering rule.", + "required" : [ + "add" + ], + "properties" : { + "add" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/RuleNoId" + } + } + } + }, + "Aggregate" : { + "type" : "integer", + "description" : "The sum of results returned in this response.", + "format" : "int32" + }, + "AllProjectClientApps" : { + "type" : "array", + "description" : "Client App Rule Counts for all applications in the project", + "items" : { + "$ref" : "#/components/schemas/AppRulesCount" + } + }, + "AnimatedGif" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "preview_image_url" : { + "type" : "string", + "format" : "uri" + }, + "variants" : { + "$ref" : "#/components/schemas/Variants" + } + } + } + ] + }, + "AppRulesCount" : { + "type" : "object", + "description" : "A count of user-provided stream filtering rules at the client application level.", + "properties" : { + "client_app_id" : { + "$ref" : "#/components/schemas/ClientAppId" + }, + "rule_count" : { + "type" : "integer", + "description" : "Number of rules for client application", + "format" : "int32" + } + } + }, + "BookmarkAddRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + }, + "BookmarkMutationResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "bookmarked" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "CashtagEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/CashtagFields" + } + ] + }, + "CashtagFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a Cashtag, and its start and end position within the text.", + "required" : [ + "tag" + ], + "properties" : { + "tag" : { + "type" : "string", + "example" : "TWTR" + } + } + }, + "ClientAppId" : { + "type" : "string", + "description" : "The ID of the client application", + "minLength" : 1, + "maxLength" : 19 + }, + "ClientAppUsage" : { + "type" : "object", + "description" : "Usage per client app", + "properties" : { + "client_app_id" : { + "type" : "string", + "description" : "The unique identifier for this project", + "format" : "^[0-9]{1,19}$" + }, + "usage" : { + "type" : "array", + "description" : "The usage value", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UsageFields" + } + }, + "usage_result_count" : { + "type" : "integer", + "description" : "The number of results returned", + "format" : "int32" + } + } + }, + "ClientDisconnectedProblem" : { + "description" : "Your client has gone away.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "ClientForbiddenProblem" : { + "description" : "A problem that indicates your client is forbidden from making this request.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "reason" : { + "type" : "string", + "enum" : [ + "official-client-forbidden", + "client-not-enrolled" + ] + }, + "registration_url" : { + "type" : "string", + "format" : "uri" + } + } + } + ] + }, + "ComplianceJob" : { + "type" : "object", + "required" : [ + "id", + "type", + "created_at", + "upload_url", + "download_url", + "upload_expires_at", + "download_expires_at", + "status" + ], + "properties" : { + "created_at" : { + "$ref" : "#/components/schemas/CreatedAt" + }, + "download_expires_at" : { + "$ref" : "#/components/schemas/DownloadExpiration" + }, + "download_url" : { + "$ref" : "#/components/schemas/DownloadUrl" + }, + "id" : { + "$ref" : "#/components/schemas/JobId" + }, + "name" : { + "$ref" : "#/components/schemas/ComplianceJobName" + }, + "status" : { + "$ref" : "#/components/schemas/ComplianceJobStatus" + }, + "type" : { + "$ref" : "#/components/schemas/ComplianceJobType" + }, + "upload_expires_at" : { + "$ref" : "#/components/schemas/UploadExpiration" + }, + "upload_url" : { + "$ref" : "#/components/schemas/UploadUrl" + } + } + }, + "ComplianceJobName" : { + "type" : "string", + "description" : "User-provided name for a compliance job.", + "maxLength" : 64, + "example" : "my-job" + }, + "ComplianceJobStatus" : { + "type" : "string", + "description" : "Status of a compliance job.", + "enum" : [ + "created", + "in_progress", + "failed", + "complete", + "expired" + ] + }, + "ComplianceJobType" : { + "type" : "string", + "description" : "Type of compliance job to list.", + "enum" : [ + "tweets", + "users" + ] + }, + "ConflictProblem" : { + "description" : "You cannot create a new job if one is already in progress.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "ConnectionExceptionProblem" : { + "description" : "A problem that indicates something is wrong with the connection.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "connection_issue" : { + "type" : "string", + "enum" : [ + "TooManyConnections", + "ProvisioningSubscription", + "RuleConfigurationIssue", + "RulesInvalidIssue" + ] + } + } + } + ] + }, + "ContextAnnotation" : { + "type" : "object", + "description" : "Annotation inferred from the Tweet text.", + "required" : [ + "domain", + "entity" + ], + "properties" : { + "domain" : { + "$ref" : "#/components/schemas/ContextAnnotationDomainFields" + }, + "entity" : { + "$ref" : "#/components/schemas/ContextAnnotationEntityFields" + } + } + }, + "ContextAnnotationDomainFields" : { + "type" : "object", + "description" : "Represents the data for the context annotation domain.", + "required" : [ + "id" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the context annotation domain." + }, + "id" : { + "type" : "string", + "description" : "The unique id for a context annotation domain.", + "pattern" : "^[0-9]{1,19}$" + }, + "name" : { + "type" : "string", + "description" : "Name of the context annotation domain." + } + } + }, + "ContextAnnotationEntityFields" : { + "type" : "object", + "description" : "Represents the data for the context annotation entity.", + "required" : [ + "id" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the context annotation entity." + }, + "id" : { + "type" : "string", + "description" : "The unique id for a context annotation entity.", + "pattern" : "^[0-9]{1,19}$" + }, + "name" : { + "type" : "string", + "description" : "Name of the context annotation entity." + } + } + }, + "CountryCode" : { + "type" : "string", + "description" : "A two-letter ISO 3166-1 alpha-2 country code.", + "pattern" : "^[A-Z]{2}$", + "example" : "US" + }, + "CreateAttachmentsMessageRequest" : { + "type" : "object", + "required" : [ + "attachments" + ], + "properties" : { + "attachments" : { + "$ref" : "#/components/schemas/DmAttachments" + }, + "text" : { + "type" : "string", + "description" : "Text of the message.", + "minLength" : 1 + } + } + }, + "CreateComplianceJobRequest" : { + "type" : "object", + "description" : "A request to create a new batch compliance job.", + "required" : [ + "type" + ], + "properties" : { + "name" : { + "$ref" : "#/components/schemas/ComplianceJobName" + }, + "resumable" : { + "type" : "boolean", + "description" : "If true, this endpoint will return a pre-signed URL with resumable uploads enabled." + }, + "type" : { + "type" : "string", + "description" : "Type of compliance job to list.", + "enum" : [ + "tweets", + "users" + ] + } + } + }, + "CreateComplianceJobResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/ComplianceJob" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "CreateDmConversationRequest" : { + "type" : "object", + "required" : [ + "conversation_type", + "participant_ids", + "message" + ], + "properties" : { + "conversation_type" : { + "type" : "string", + "description" : "The conversation type that is being created.", + "enum" : [ + "Group" + ] + }, + "message" : { + "$ref" : "#/components/schemas/CreateMessageRequest" + }, + "participant_ids" : { + "$ref" : "#/components/schemas/DmParticipants" + } + }, + "additionalProperties" : false + }, + "CreateDmEventResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "dm_conversation_id", + "dm_event_id" + ], + "properties" : { + "dm_conversation_id" : { + "$ref" : "#/components/schemas/DmConversationId" + }, + "dm_event_id" : { + "$ref" : "#/components/schemas/DmEventId" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "CreateMessageRequest" : { + "anyOf" : [ + { + "$ref" : "#/components/schemas/CreateTextMessageRequest" + }, + { + "$ref" : "#/components/schemas/CreateAttachmentsMessageRequest" + } + ] + }, + "CreateTextMessageRequest" : { + "type" : "object", + "required" : [ + "text" + ], + "properties" : { + "attachments" : { + "$ref" : "#/components/schemas/DmAttachments" + }, + "text" : { + "type" : "string", + "description" : "Text of the message.", + "minLength" : 1 + } + } + }, + "CreatedAt" : { + "type" : "string", + "description" : "Creation time of the compliance job.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "DeleteDmResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "deleted" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "DeleteRulesRequest" : { + "type" : "object", + "description" : "A response from deleting user-specified stream filtering rules.", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "type" : "object", + "description" : "IDs and values of all deleted user-specified stream filtering rules.", + "properties" : { + "ids" : { + "type" : "array", + "description" : "IDs of all deleted user-specified stream filtering rules.", + "items" : { + "$ref" : "#/components/schemas/RuleId" + } + }, + "values" : { + "type" : "array", + "description" : "Values of all deleted user-specified stream filtering rules.", + "items" : { + "$ref" : "#/components/schemas/RuleValue" + } + } + } + } + } + }, + "DisallowedResourceProblem" : { + "description" : "A problem that indicates that the resource requested violates the precepts of this API.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "resource_id", + "resource_type", + "section" + ], + "properties" : { + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] + } + } + } + ] + }, + "DmAttachments" : { + "type" : "array", + "description" : "Attachments to a DM Event.", + "items" : { + "$ref" : "#/components/schemas/DmMediaAttachment" + } + }, + "DmConversationId" : { + "type" : "string", + "description" : "Unique identifier of a DM conversation. This can either be a numeric string, or a pair of numeric strings separated by a '-' character in the case of one-on-one DM Conversations.", + "pattern" : "^([0-9]{1,19}-[0-9]{1,19}|[0-9]{15,19})$", + "example" : "123123123-456456456" + }, + "DmEvent" : { + "type" : "object", + "required" : [ + "id", + "event_type" + ], + "properties" : { + "attachments" : { + "type" : "object", + "description" : "Specifies the type of attachments (if any) present in this DM.", + "properties" : { + "card_ids" : { + "type" : "array", + "description" : "A list of card IDs (if cards are attached).", + "minItems" : 1, + "items" : { + "type" : "string" + } + }, + "media_keys" : { + "type" : "array", + "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MediaKey" + } + } + } + }, + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" + } + }, + "created_at" : { + "type" : "string", + "format" : "date-time" + }, + "dm_conversation_id" : { + "$ref" : "#/components/schemas/DmConversationId" + }, + "event_type" : { + "type" : "string", + "example" : "MessageCreate" + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" + } + }, + "id" : { + "$ref" : "#/components/schemas/DmEventId" + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" + } + }, + "participant_ids" : { + "type" : "array", + "description" : "A list of participants for a ParticipantsJoin or ParticipantsLeave event_type.", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "referenced_tweets" : { + "type" : "array", + "description" : "A list of Posts this DM refers to.", + "minItems" : 1, + "items" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + } + }, + "sender_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "text" : { + "type" : "string" + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntityDm" + } + } + } + }, + "DmEventId" : { + "type" : "string", + "description" : "Unique identifier of a DM Event.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "DmMediaAttachment" : { + "type" : "object", + "required" : [ + "media_id" + ], + "properties" : { + "media_id" : { + "$ref" : "#/components/schemas/MediaId" + } + } + }, + "DmParticipants" : { + "type" : "array", + "description" : "Participants for the DM Conversation.", + "minItems" : 2, + "maxItems" : 49, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "DownloadExpiration" : { + "type" : "string", + "description" : "Expiration time of the download URL.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "DownloadUrl" : { + "type" : "string", + "description" : "URL from which the user will retrieve their compliance results.", + "format" : "uri" + }, + "DuplicateRuleProblem" : { + "description" : "The rule you have submitted is a duplicate.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "id" : { + "type" : "string" + }, + "value" : { + "type" : "string" + } + } + } + ] + }, + "End" : { + "type" : "string", + "description" : "The end time of the bucket.", + "format" : "date-time" + }, + "EntityIndicesInclusiveExclusive" : { + "type" : "object", + "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is exclusive.", + "required" : [ + "start", + "end" + ], + "properties" : { + "end" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity ends. The index is exclusive.", + "minimum" : 0, + "example" : 61 + }, + "start" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", + "minimum" : 0, + "example" : 50 + } + } + }, + "EntityIndicesInclusiveInclusive" : { + "type" : "object", + "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is inclusive.", + "required" : [ + "start", + "end" + ], + "properties" : { + "end" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity ends. The index is inclusive.", + "minimum" : 0, + "example" : 61 + }, + "start" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", + "minimum" : 0, + "example" : 50 + } + } + }, + "Error" : { + "type" : "object", + "required" : [ + "code", + "message" + ], + "properties" : { + "code" : { + "type" : "integer", + "format" : "int32" + }, + "message" : { + "type" : "string" + } + } + }, + "Expansions" : { + "type" : "object", + "properties" : { + "media" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Media" + } + }, + "places" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Place" + } + }, + "polls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Poll" + } + }, + "topics" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Topic" + } + }, + "tweets" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "users" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + } + } + }, + "FieldUnauthorizedProblem" : { + "description" : "A problem that indicates that you are not allowed to see a particular field on a Tweet, User, etc.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "resource_type", + "field", + "section" + ], + "properties" : { + "field" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] + } + } + } + ] + }, + "FilteredStreamingTweetResponse" : { + "type" : "object", + "description" : "A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched.", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "matching_rules" : { + "type" : "array", + "description" : "The list of rules which matched the Tweet", + "items" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/RuleId" + }, + "tag" : { + "$ref" : "#/components/schemas/RuleTag" + } + } + } + } + } + }, + "FullTextEntities" : { + "type" : "object", + "properties" : { + "annotations" : { + "type" : "array", + "minItems" : 1, + "items" : { + "description" : "Annotation for entities based on the Tweet text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveInclusive" + }, + { + "type" : "object", + "description" : "Represents the data for the annotation.", + "properties" : { + "normalized_text" : { + "type" : "string", + "description" : "Text used to determine annotation.", + "example" : "Barack Obama" + }, + "probability" : { + "type" : "number", + "description" : "Confidence factor for annotation type.", + "minimum" : 0, + "maximum" : 1, + "format" : "double" + }, + "type" : { + "type" : "string", + "description" : "Annotation type.", + "example" : "Person" + } + } + } + ] + } + }, + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" + } + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" + } + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" + } + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" + } + } + } + }, + "GenericProblem" : { + "description" : "A generic problem with no additional information beyond that provided by the HTTP status code.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "Geo" : { + "type" : "object", + "required" : [ + "type", + "bbox", + "properties" + ], + "properties" : { + "bbox" : { + "type" : "array", + "minItems" : 4, + "maxItems" : 4, + "items" : { + "type" : "number", + "minimum" : -180, + "maximum" : 180, + "format" : "double" + }, + "example" : [ + -105.193475, + 39.60973, + -105.053164, + 39.761974 + ] + }, + "geometry" : { + "$ref" : "#/components/schemas/Point" + }, + "properties" : { + "type" : "object" + }, + "type" : { + "type" : "string", + "enum" : [ + "Feature" + ] + } + } + }, + "Get2ComplianceJobsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/ComplianceJob" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Get2ComplianceJobsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ComplianceJob" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2DmConversationsIdDmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2DmConversationsWithParticipantIdDmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2DmEventsEventIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/DmEvent" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2DmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2LikesFirehoseStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2LikesSample10StreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2ListsIdFollowersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2ListsIdMembersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2ListsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/List" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2ListsIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2SpacesByCreatorIdsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2SpacesIdBuyersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2SpacesIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Space" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2SpacesIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2SpacesResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2SpacesSearchResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TrendsByWoeidWoeidResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Trend" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Get2TweetsCountsAllResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/SearchCount" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "total_tweet_count" : { + "$ref" : "#/components/schemas/Aggregate" + } + } + } + } + }, + "Get2TweetsCountsRecentResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/SearchCount" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "total_tweet_count" : { + "$ref" : "#/components/schemas/Aggregate" + } + } + } + } + }, + "Get2TweetsFirehoseStreamLangEnResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsFirehoseStreamLangJaResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsFirehoseStreamLangKoResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsFirehoseStreamLangPtResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsFirehoseStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsIdLikingUsersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsIdQuoteTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsIdRetweetedByResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsIdRetweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsSample10StreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsSampleStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsSearchAllResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsSearchRecentResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2TweetsSearchStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2TweetsSearchStreamRulesCountsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/RulesCount" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Get2UsageTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Usage" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Get2UsersByResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2UsersByUsernameUsernameResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2UsersIdBlockingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdBookmarksResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdFollowedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdFollowersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdFollowingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdLikedTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdListMembershipsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdMentionsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdMutingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdOwnedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdPinnedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2UsersIdTimelinesReverseChronologicalResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } + } + } + } + }, + "Get2UsersMeResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2UsersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Get2UsersSearchResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + } + } + } + } + }, + "HashtagEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/HashtagFields" + } + ] + }, + "HashtagFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a Hashtag, and its start and end position within the text.", + "required" : [ + "tag" + ], + "properties" : { + "tag" : { + "type" : "string", + "description" : "The text of the Hashtag.", + "example" : "MondayMotivation" + } + } + }, + "HttpStatusCode" : { + "type" : "integer", + "description" : "HTTP Status Code.", + "minimum" : 100, + "maximum" : 599 + }, + "InvalidRequestProblem" : { + "description" : "A problem that indicates this request is invalid.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "type" : "object", + "properties" : { + "message" : { + "type" : "string" + }, + "parameters" : { + "type" : "object", + "additionalProperties" : { + "type" : "array", + "items" : { + "type" : "string" + } + } + } + } + } + } + } + } + ] + }, + "InvalidRuleProblem" : { + "description" : "The rule you have submitted is invalid.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "JobId" : { + "type" : "string", + "description" : "Compliance Job ID.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1372966999991541762" + }, + "Like" : { + "type" : "object", + "description" : "A Like event, with the liking user and the tweet being liked", + "properties" : { + "created_at" : { + "type" : "string", + "description" : "Creation time of the Tweet.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "id" : { + "$ref" : "#/components/schemas/LikeId" + }, + "liked_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "liking_user_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "timestamp_ms" : { + "type" : "integer", + "description" : "Timestamp in milliseconds of creation.", + "format" : "int32" + } + } + }, + "LikeComplianceSchema" : { + "type" : "object", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "$ref" : "#/components/schemas/UnlikeComplianceSchema" + } + } + }, + "LikeId" : { + "type" : "string", + "description" : "The unique identifier of this Like.", + "pattern" : "^[A-Za-z0-9_]{1,40}$", + "example" : "8ba4f34e6235d905a46bac021d98e923" + }, + "LikesComplianceStreamResponse" : { + "description" : "Likes compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/LikeComplianceSchema" + } + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + ] + }, + "List" : { + "type" : "object", + "description" : "A X List is a curated group of accounts.", + "required" : [ + "id", + "name" + ], + "properties" : { + "created_at" : { + "type" : "string", + "format" : "date-time" + }, + "description" : { + "type" : "string" + }, + "follower_count" : { + "type" : "integer" + }, + "id" : { + "$ref" : "#/components/schemas/ListId" + }, + "member_count" : { + "type" : "integer" + }, + "name" : { + "type" : "string", + "description" : "The name of this List." + }, + "owner_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "private" : { + "type" : "boolean" + } + } + }, + "ListAddUserRequest" : { + "type" : "object", + "required" : [ + "user_id" + ], + "properties" : { + "user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "ListCreateRequest" : { + "type" : "object", + "required" : [ + "name" + ], + "properties" : { + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + }, + "name" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 25 + }, + "private" : { + "type" : "boolean", + "default" : false + } + } + }, + "ListCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "description" : "A X List is a curated group of accounts.", + "required" : [ + "id", + "name" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/ListId" + }, + "name" : { + "type" : "string", + "description" : "The name of this List." + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "deleted" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListFollowedRequest" : { + "type" : "object", + "required" : [ + "list_id" + ], + "properties" : { + "list_id" : { + "$ref" : "#/components/schemas/ListId" + } + } + }, + "ListFollowedResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListId" : { + "type" : "string", + "description" : "The unique identifier of this List.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "ListMutateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "is_member" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListPinnedRequest" : { + "type" : "object", + "required" : [ + "list_id" + ], + "properties" : { + "list_id" : { + "$ref" : "#/components/schemas/ListId" + } + } + }, + "ListPinnedResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "pinned" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListUnpinResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "pinned" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "ListUpdateRequest" : { + "type" : "object", + "properties" : { + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + }, + "name" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 25 + }, + "private" : { + "type" : "boolean" + } + } + }, + "ListUpdateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "updated" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Media" : { + "type" : "object", + "required" : [ + "type" + ], + "properties" : { + "height" : { + "$ref" : "#/components/schemas/MediaHeight" + }, + "media_key" : { + "$ref" : "#/components/schemas/MediaKey" + }, + "type" : { + "type" : "string" + }, + "width" : { + "$ref" : "#/components/schemas/MediaWidth" + } + }, + "discriminator" : { + "propertyName" : "type", + "mapping" : { + "animated_gif" : "#/components/schemas/AnimatedGif", + "photo" : "#/components/schemas/Photo", + "video" : "#/components/schemas/Video" + } + } + }, + "MediaHeight" : { + "type" : "integer", + "description" : "The height of the media in pixels.", + "minimum" : 0 + }, + "MediaId" : { + "type" : "string", + "description" : "The unique identifier of this Media.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "MediaKey" : { + "type" : "string", + "description" : "The Media Key identifier for this attachment.", + "pattern" : "^([0-9]+)_([0-9]+)$" + }, + "MediaWidth" : { + "type" : "integer", + "description" : "The width of the media in pixels.", + "minimum" : 0 + }, + "MentionEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/MentionFields" + } + ] + }, + "MentionFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a User mention, and its start and end position within the text.", + "required" : [ + "username" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + }, + "username" : { + "$ref" : "#/components/schemas/UserName" + } + } + }, + "MuteUserMutationResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "muting" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "MuteUserRequest" : { + "type" : "object", + "required" : [ + "target_user_id" + ], + "properties" : { + "target_user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "NewestId" : { + "type" : "string", + "description" : "The newest id in this response." + }, + "NextToken" : { + "type" : "string", + "description" : "The next token.", + "minLength" : 1 + }, + "NonCompliantRulesProblem" : { + "description" : "A problem that indicates the user's rule set is not compliant.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "NoteTweetText" : { + "type" : "string", + "description" : "The note content of the Tweet.", + "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" + }, + "Oauth1PermissionsProblem" : { + "description" : "A problem that indicates your client application does not have the required OAuth1 permissions for the requested endpoint.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "OldestId" : { + "type" : "string", + "description" : "The oldest id in this response." + }, + "OperationalDisconnectProblem" : { + "description" : "You have been disconnected for operational reasons.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "disconnect_type" : { + "type" : "string", + "enum" : [ + "OperationalDisconnect", + "UpstreamOperationalDisconnect", + "ForceDisconnect", + "UpstreamUncleanDisconnect", + "SlowReader", + "InternalError", + "ClientApplicationStateDegraded", + "InvalidRules" + ] + } + } + } + ] + }, + "PaginationToken32" : { + "type" : "string", + "description" : "A base32 pagination token.", + "minLength" : 16 + }, + "PaginationToken36" : { + "type" : "string", + "description" : "A base36 pagination token.", + "minLength" : 1 + }, + "PaginationTokenLong" : { + "type" : "string", + "description" : "A 'long' pagination token.", + "minLength" : 1, + "maxLength" : 19 + }, + "Photo" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "alt_text" : { + "type" : "string" + }, + "url" : { + "type" : "string", + "format" : "uri" + } + } + } + ] + }, + "Place" : { + "type" : "object", + "required" : [ + "id", + "full_name" + ], + "properties" : { + "contained_within" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/PlaceId" + } + }, + "country" : { + "type" : "string", + "description" : "The full name of the county in which this place exists.", + "example" : "United States" + }, + "country_code" : { + "$ref" : "#/components/schemas/CountryCode" + }, + "full_name" : { + "type" : "string", + "description" : "The full name of this place.", + "example" : "Lakewood, CO" + }, + "geo" : { + "$ref" : "#/components/schemas/Geo" + }, + "id" : { + "$ref" : "#/components/schemas/PlaceId" + }, + "name" : { + "type" : "string", + "description" : "The human readable name of this place.", + "example" : "Lakewood" + }, + "place_type" : { + "$ref" : "#/components/schemas/PlaceType" + } + } + }, + "PlaceId" : { + "type" : "string", + "description" : "The identifier for this place.", + "example" : "f7eb2fa2fea288b1" + }, + "PlaceType" : { + "type" : "string", + "enum" : [ + "poi", + "neighborhood", + "city", + "admin", + "country", + "unknown" + ], + "example" : "city" + }, + "Point" : { + "type" : "object", + "description" : "A [GeoJson Point](https://tools.ietf.org/html/rfc7946#section-3.1.2) geometry object.", + "required" : [ + "type", + "coordinates" + ], + "properties" : { + "coordinates" : { + "$ref" : "#/components/schemas/Position" + }, + "type" : { + "type" : "string", + "enum" : [ + "Point" + ], + "example" : "Point" + } + } + }, + "Poll" : { + "type" : "object", + "description" : "Represent a Poll attached to a Tweet.", + "required" : [ + "id", + "options" + ], + "properties" : { + "duration_minutes" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 10080, + "format" : "int32" + }, + "end_datetime" : { + "type" : "string", + "format" : "date-time" + }, + "id" : { + "$ref" : "#/components/schemas/PollId" + }, + "options" : { + "type" : "array", + "minItems" : 2, + "maxItems" : 4, + "items" : { + "$ref" : "#/components/schemas/PollOption" + } + }, + "voting_status" : { + "type" : "string", + "enum" : [ + "open", + "closed" + ] + } + } + }, + "PollId" : { + "type" : "string", + "description" : "Unique identifier of this poll.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1365059861688410112" + }, + "PollOption" : { + "type" : "object", + "description" : "Describes a choice in a Poll object.", + "required" : [ + "position", + "label", + "votes" + ], + "properties" : { + "label" : { + "$ref" : "#/components/schemas/PollOptionLabel" + }, + "position" : { + "type" : "integer", + "description" : "Position of this choice in the poll." + }, + "votes" : { + "type" : "integer", + "description" : "Number of users who voted for this choice." + } + } + }, + "PollOptionLabel" : { + "type" : "string", + "description" : "The text of a poll choice.", + "minLength" : 1, + "maxLength" : 25 + }, + "Position" : { + "type" : "array", + "description" : "A [GeoJson Position](https://tools.ietf.org/html/rfc7946#section-3.1.1) in the format `[longitude,latitude]`.", + "minItems" : 2, + "maxItems" : 2, + "items" : { + "type" : "number" + }, + "example" : [ + -105.18816086351444, + 40.247749999999996 + ] + }, + "PreviousToken" : { + "type" : "string", + "description" : "The previous token.", + "minLength" : 1 + }, + "Problem" : { + "type" : "object", + "description" : "An HTTP Problem Details object, as defined in IETF RFC 7807 (https://tools.ietf.org/html/rfc7807).", + "required" : [ + "type", + "title" + ], + "properties" : { + "detail" : { + "type" : "string" + }, + "status" : { + "type" : "integer" + }, + "title" : { + "type" : "string" + }, + "type" : { + "type" : "string" + } + }, + "discriminator" : { + "propertyName" : "type", + "mapping" : { + "about:blank" : "#/components/schemas/GenericProblem", + "https://api.twitter.com/2/problems/client-disconnected" : "#/components/schemas/ClientDisconnectedProblem", + "https://api.twitter.com/2/problems/client-forbidden" : "#/components/schemas/ClientForbiddenProblem", + "https://api.twitter.com/2/problems/conflict" : "#/components/schemas/ConflictProblem", + "https://api.twitter.com/2/problems/disallowed-resource" : "#/components/schemas/DisallowedResourceProblem", + "https://api.twitter.com/2/problems/duplicate-rules" : "#/components/schemas/DuplicateRuleProblem", + "https://api.twitter.com/2/problems/invalid-request" : "#/components/schemas/InvalidRequestProblem", + "https://api.twitter.com/2/problems/invalid-rules" : "#/components/schemas/InvalidRuleProblem", + "https://api.twitter.com/2/problems/noncompliant-rules" : "#/components/schemas/NonCompliantRulesProblem", + "https://api.twitter.com/2/problems/not-authorized-for-field" : "#/components/schemas/FieldUnauthorizedProblem", + "https://api.twitter.com/2/problems/not-authorized-for-resource" : "#/components/schemas/ResourceUnauthorizedProblem", + "https://api.twitter.com/2/problems/oauth1-permissions" : "#/components/schemas/Oauth1PermissionsProblem", + "https://api.twitter.com/2/problems/operational-disconnect" : "#/components/schemas/OperationalDisconnectProblem", + "https://api.twitter.com/2/problems/resource-not-found" : "#/components/schemas/ResourceNotFoundProblem", + "https://api.twitter.com/2/problems/resource-unavailable" : "#/components/schemas/ResourceUnavailableProblem", + "https://api.twitter.com/2/problems/rule-cap" : "#/components/schemas/RulesCapProblem", + "https://api.twitter.com/2/problems/streaming-connection" : "#/components/schemas/ConnectionExceptionProblem", + "https://api.twitter.com/2/problems/unsupported-authentication" : "#/components/schemas/UnsupportedAuthenticationProblem", + "https://api.twitter.com/2/problems/usage-capped" : "#/components/schemas/UsageCapExceededProblem" + } + } + }, + "ReplySettings" : { + "type" : "string", + "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, and following.", + "pattern" : "^[A-Za-z]{1,12}$", + "enum" : [ + "everyone", + "mentionedUsers", + "following", + "other" + ] + }, + "ReplySettingsWithVerifiedUsers" : { + "type" : "string", + "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, subscribers, verified and following.", + "pattern" : "^[A-Za-z]{1,12}$", + "enum" : [ + "everyone", + "mentionedUsers", + "following", + "other", + "subscribers", + "verified" + ] + }, + "ResourceNotFoundProblem" : { + "description" : "A problem that indicates that a given Tweet, User, etc. does not exist.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "parameter", + "value", + "resource_id", + "resource_type" + ], + "properties" : { + "parameter" : { + "type" : "string", + "minLength" : 1 + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "value" : { + "type" : "string", + "description" : "Value will match the schema of the field." + } + } + } + ] + }, + "ResourceUnauthorizedProblem" : { + "description" : "A problem that indicates you are not allowed to see a particular Tweet, User, etc.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "value", + "resource_id", + "resource_type", + "section", + "parameter" + ], + "properties" : { + "parameter" : { + "type" : "string" + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] + }, + "value" : { + "type" : "string" + } + } + } + ] + }, + "ResourceUnavailableProblem" : { + "description" : "A problem that indicates a particular Tweet, User, etc. is not available to you.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "parameter", + "resource_id", + "resource_type" + ], + "properties" : { + "parameter" : { + "type" : "string", + "minLength" : 1 + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + } + } + } + ] + }, + "ResultCount" : { + "type" : "integer", + "description" : "The number of results returned in this response.", + "format" : "int32" + }, + "Rule" : { + "type" : "object", + "description" : "A user-provided stream filtering rule.", + "required" : [ + "value" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/RuleId" + }, + "tag" : { + "$ref" : "#/components/schemas/RuleTag" + }, + "value" : { + "$ref" : "#/components/schemas/RuleValue" + } + } + }, + "RuleId" : { + "type" : "string", + "description" : "Unique identifier of this rule.", + "pattern" : "^[0-9]{1,19}$", + "example" : "120897978112909812" + }, + "RuleNoId" : { + "type" : "object", + "description" : "A user-provided stream filtering rule.", + "required" : [ + "value" + ], + "properties" : { + "tag" : { + "$ref" : "#/components/schemas/RuleTag" + }, + "value" : { + "$ref" : "#/components/schemas/RuleValue" + } + } + }, + "RuleTag" : { + "type" : "string", + "description" : "A tag meant for the labeling of user provided rules.", + "example" : "Non-retweeted coffee Posts" + }, + "RuleValue" : { + "type" : "string", + "description" : "The filterlang value of the rule.", + "example" : "coffee -is:retweet" + }, + "RulesCapProblem" : { + "description" : "You have exceeded the maximum number of rules.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "RulesCount" : { + "type" : "object", + "description" : "A count of user-provided stream filtering rules at the application and project levels.", + "properties" : { + "all_project_client_apps" : { + "$ref" : "#/components/schemas/AllProjectClientApps" + }, + "cap_per_client_app" : { + "type" : "integer", + "description" : "Cap of number of rules allowed per client application", + "format" : "int32" + }, + "cap_per_project" : { + "type" : "integer", + "description" : "Cap of number of rules allowed per project", + "format" : "int32" + }, + "client_app_rules_count" : { + "$ref" : "#/components/schemas/AppRulesCount" + }, + "project_rules_count" : { + "type" : "integer", + "description" : "Number of rules for project", + "format" : "int32" + } + } + }, + "RulesLookupResponse" : { + "type" : "object", + "required" : [ + "meta" + ], + "properties" : { + "data" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Rule" + } + }, + "meta" : { + "$ref" : "#/components/schemas/RulesResponseMetadata" + } + } + }, + "RulesRequestSummary" : { + "oneOf" : [ + { + "type" : "object", + "description" : "A summary of the results of the addition of user-specified stream filtering rules.", + "required" : [ + "created", + "not_created", + "valid", + "invalid" + ], + "properties" : { + "created" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were created.", + "format" : "int32", + "example" : 1 + }, + "invalid" : { + "type" : "integer", + "description" : "Number of invalid user-specified stream filtering rules.", + "format" : "int32", + "example" : 1 + }, + "not_created" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were not created.", + "format" : "int32", + "example" : 1 + }, + "valid" : { + "type" : "integer", + "description" : "Number of valid user-specified stream filtering rules.", + "format" : "int32", + "example" : 1 + } + } + }, + { + "type" : "object", + "required" : [ + "deleted", + "not_deleted" + ], + "properties" : { + "deleted" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were deleted.", + "format" : "int32" + }, + "not_deleted" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were not deleted.", + "format" : "int32" + } + } + } + ] + }, + "RulesResponseMetadata" : { + "type" : "object", + "required" : [ + "sent" + ], + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "result_count" : { + "type" : "integer", + "description" : "Number of Rules in result set.", + "format" : "int32" + }, + "sent" : { + "type" : "string" + }, + "summary" : { + "$ref" : "#/components/schemas/RulesRequestSummary" + } + } + }, + "SearchCount" : { + "type" : "object", + "description" : "Represent a Search Count Result.", + "required" : [ + "end", + "start", + "tweet_count" + ], + "properties" : { + "end" : { + "$ref" : "#/components/schemas/End" + }, + "start" : { + "$ref" : "#/components/schemas/Start" + }, + "tweet_count" : { + "$ref" : "#/components/schemas/TweetCount" + } + } + }, + "Space" : { + "type" : "object", + "description" : "", + "required" : [ + "id", + "state" + ], + "properties" : { + "created_at" : { + "type" : "string", + "description" : "Creation time of the Space.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "creator_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "ended_at" : { + "type" : "string", + "description" : "End time of the Space.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "host_ids" : { + "type" : "array", + "description" : "The user ids for the hosts of the Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "id" : { + "$ref" : "#/components/schemas/SpaceId" + }, + "invited_user_ids" : { + "type" : "array", + "description" : "An array of user ids for people who were invited to a Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "is_ticketed" : { + "type" : "boolean", + "description" : "Denotes if the Space is a ticketed Space.", + "example" : "false" + }, + "lang" : { + "type" : "string", + "description" : "The language of the Space.", + "example" : "en" + }, + "participant_count" : { + "type" : "integer", + "description" : "The number of participants in a Space.", + "format" : "int32", + "example" : 10 + }, + "scheduled_start" : { + "type" : "string", + "description" : "A date time stamp for when a Space is scheduled to begin.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "speaker_ids" : { + "type" : "array", + "description" : "An array of user ids for people who were speakers in a Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "started_at" : { + "type" : "string", + "description" : "When the Space was started as a date string.", + "format" : "date-time", + "example" : "2021-7-14T04:35:55Z" + }, + "state" : { + "type" : "string", + "description" : "The current state of the Space.", + "enum" : [ + "live", + "scheduled", + "ended" + ], + "example" : "live" + }, + "subscriber_count" : { + "type" : "integer", + "description" : "The number of people who have either purchased a ticket or set a reminder for this Space.", + "format" : "int32", + "example" : 10 + }, + "title" : { + "type" : "string", + "description" : "The title of the Space.", + "example" : "Spaces are Awesome" + }, + "topics" : { + "type" : "array", + "description" : "The topics of a Space, as selected by its creator.", + "items" : { + "type" : "object", + "description" : "The X Topic object.", + "required" : [ + "id", + "name" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "The description of the given topic." + }, + "id" : { + "type" : "string", + "description" : "An ID suitable for use in the REST API." + }, + "name" : { + "type" : "string", + "description" : "The name of the given topic." + } + }, + "example" : { + "description" : "All about technology", + "id" : "848920371311001600", + "name" : "Technology" + } + } + }, + "updated_at" : { + "type" : "string", + "description" : "When the Space was last updated.", + "format" : "date-time", + "example" : "2021-7-14T04:35:55Z" + } + } + }, + "SpaceId" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "Start" : { + "type" : "string", + "description" : "The start time of the bucket.", + "format" : "date-time" + }, + "StreamingLikeResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "StreamingTweetResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Topic" : { + "type" : "object", + "description" : "The topic of a Space, as selected by its creator.", + "required" : [ + "id", + "name" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "The description of the given topic.", + "example" : "All about technology" + }, + "id" : { + "$ref" : "#/components/schemas/TopicId" + }, + "name" : { + "type" : "string", + "description" : "The name of the given topic.", + "example" : "Technology" + } + } + }, + "TopicId" : { + "type" : "string", + "description" : "Unique identifier of this Topic." + }, + "Trend" : { + "type" : "object", + "description" : "A trend.", + "properties" : { + "trend_name" : { + "type" : "string", + "description" : "Name of the trend." + }, + "tweet_count" : { + "type" : "integer", + "description" : "Number of Posts in this trend.", + "format" : "int32" + } + } + }, + "Tweet" : { + "type" : "object", + "properties" : { + "attachments" : { + "type" : "object", + "description" : "Specifies the type of attachments (if any) present in this Tweet.", + "properties" : { + "media_keys" : { + "type" : "array", + "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MediaKey" + } + }, + "media_source_tweet_id" : { + "type" : "array", + "description" : "A list of Posts the media on this Tweet was originally posted in. For example, if the media on a tweet is re-used in another Tweet, this refers to the original, source Tweet..", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "poll_ids" : { + "type" : "array", + "description" : "A list of poll IDs (if polls are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/PollId" + } + } + } + }, + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "context_annotations" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ContextAnnotation" + } + }, + "conversation_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "created_at" : { + "type" : "string", + "description" : "Creation time of the Tweet.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "edit_controls" : { + "type" : "object", + "required" : [ + "is_edit_eligible", + "editable_until", + "edits_remaining" + ], + "properties" : { + "editable_until" : { + "type" : "string", + "description" : "Time when Tweet is no longer editable.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "edits_remaining" : { + "type" : "integer", + "description" : "Number of times this Tweet can be edited." + }, + "is_edit_eligible" : { + "type" : "boolean", + "description" : "Indicates if this Tweet is eligible to be edited.", + "example" : false + } + } + }, + "edit_history_tweet_ids" : { + "type" : "array", + "description" : "A list of Tweet Ids in this Tweet chain.", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "entities" : { + "$ref" : "#/components/schemas/FullTextEntities" + }, + "geo" : { + "type" : "object", + "description" : "The location tagged on the Tweet, if the user provided one.", + "properties" : { + "coordinates" : { + "$ref" : "#/components/schemas/Point" + }, + "place_id" : { + "$ref" : "#/components/schemas/PlaceId" + } + } + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "in_reply_to_user_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "lang" : { + "type" : "string", + "description" : "Language of the Tweet, if detected by X. Returned as a BCP47 language tag.", + "example" : "en" + }, + "non_public_metrics" : { + "type" : "object", + "description" : "Nonpublic engagement metrics for the Tweet at the time of the request.", + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + } + } + }, + "note_tweet" : { + "type" : "object", + "description" : "The full-content of the Tweet, including text beyond 280 characters.", + "properties" : { + "entities" : { + "type" : "object", + "properties" : { + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" + } + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" + } + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" + } + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" + } + } + } + }, + "text" : { + "$ref" : "#/components/schemas/NoteTweetText" + } + } + }, + "organic_metrics" : { + "type" : "object", + "description" : "Organic nonpublic engagement metrics for the Tweet at the time of the request.", + "required" : [ + "impression_count", + "retweet_count", + "reply_count", + "like_count" + ], + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed." + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked." + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to." + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted." + } + } + }, + "possibly_sensitive" : { + "type" : "boolean", + "description" : "Indicates if this Tweet contains URLs marked as sensitive, for example content suitable for mature audiences.", + "example" : false + }, + "promoted_metrics" : { + "type" : "object", + "description" : "Promoted nonpublic engagement metrics for the Tweet at the time of the request.", + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked.", + "format" : "int32" + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to.", + "format" : "int32" + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted.", + "format" : "int32" + } + } + }, + "public_metrics" : { + "type" : "object", + "description" : "Engagement metrics for the Tweet at the time of the request.", + "required" : [ + "retweet_count", + "reply_count", + "like_count", + "impression_count", + "bookmark_count" + ], + "properties" : { + "bookmark_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been bookmarked.", + "format" : "int32" + }, + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked." + }, + "quote_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been quoted." + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to." + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted." + } + } + }, + "referenced_tweets" : { + "type" : "array", + "description" : "A list of Posts this Tweet refers to. For example, if the parent Tweet is a Retweet, a Quoted Tweet or a Reply, it will include the related Tweet referenced to by its parent.", + "minItems" : 1, + "items" : { + "type" : "object", + "required" : [ + "type", + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "type" : { + "type" : "string", + "enum" : [ + "retweeted", + "quoted", + "replied_to" + ] + } + } + } + }, + "reply_settings" : { + "$ref" : "#/components/schemas/ReplySettingsWithVerifiedUsers" + }, + "scopes" : { + "type" : "object", + "description" : "The scopes for this tweet", + "properties" : { + "followers" : { + "type" : "boolean", + "description" : "Indicates if this Tweet is viewable by followers without the Tweet ID", + "example" : false + } + } + }, + "source" : { + "type" : "string", + "description" : "This is deprecated." + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" + }, + "username" : { + "$ref" : "#/components/schemas/UserName" + }, + "withheld" : { + "$ref" : "#/components/schemas/TweetWithheld" + } + }, + "example" : { + "author_id" : "2244994945", + "created_at" : "Wed Jan 06 18:40:40 +0000 2021", + "id" : "1346889436626259968", + "text" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i", + "username" : "XDevelopers" + } + }, + "TweetComplianceData" : { + "description" : "Tweet compliance data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/TweetDeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetWithheldComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetDropComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetUndropComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetEditComplianceSchema" + } + ] + }, + "TweetComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + } + } + }, + "TweetComplianceStreamResponse" : { + "description" : "Tweet compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/TweetComplianceData" + } + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + ] + }, + "TweetCount" : { + "type" : "integer", + "description" : "The count for the bucket." + }, + "TweetCreateRequest" : { + "type" : "object", + "properties" : { + "card_uri" : { + "type" : "string", + "description" : "Card Uri Parameter. This is mutually exclusive from Quote Tweet Id, Poll, Media, and Direct Message Deep Link." + }, + "direct_message_deep_link" : { + "type" : "string", + "description" : "Link to take the conversation from the public timeline to a private Direct Message." + }, + "for_super_followers_only" : { + "type" : "boolean", + "description" : "Exclusive Tweet for super followers.", + "default" : false + }, + "geo" : { + "type" : "object", + "description" : "Place ID being attached to the Tweet for geo location.", + "properties" : { + "place_id" : { + "type" : "string" + } + }, + "additionalProperties" : false + }, + "media" : { + "type" : "object", + "description" : "Media information being attached to created Tweet. This is mutually exclusive from Quote Tweet Id, Poll, and Card URI.", + "required" : [ + "media_ids" + ], + "properties" : { + "media_ids" : { + "type" : "array", + "description" : "A list of Media Ids to be attached to a created Tweet.", + "minItems" : 1, + "maxItems" : 4, + "items" : { + "$ref" : "#/components/schemas/MediaId" + } + }, + "tagged_user_ids" : { + "type" : "array", + "description" : "A list of User Ids to be tagged in the media for created Tweet.", + "minItems" : 0, + "maxItems" : 10, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "additionalProperties" : false + }, + "nullcast" : { + "type" : "boolean", + "description" : "Nullcasted (promoted-only) Posts do not appear in the public timeline and are not served to followers.", + "default" : false + }, + "poll" : { + "type" : "object", + "description" : "Poll options for a Tweet with a poll. This is mutually exclusive from Media, Quote Tweet Id, and Card URI.", + "required" : [ + "options", + "duration_minutes" + ], + "properties" : { + "duration_minutes" : { + "type" : "integer", + "description" : "Duration of the poll in minutes.", + "minimum" : 5, + "maximum" : 10080, + "format" : "int32" + }, + "options" : { + "type" : "array", + "minItems" : 2, + "maxItems" : 4, + "items" : { + "type" : "string", + "description" : "The text of a poll choice.", + "minLength" : 1, + "maxLength" : 25 + } + }, + "reply_settings" : { + "type" : "string", + "description" : "Settings to indicate who can reply to the Tweet.", + "enum" : [ + "following", + "mentionedUsers" + ] + } + }, + "additionalProperties" : false + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "reply" : { + "type" : "object", + "description" : "Tweet information of the Tweet being replied to.", + "required" : [ + "in_reply_to_tweet_id" + ], + "properties" : { + "exclude_reply_user_ids" : { + "type" : "array", + "description" : "A list of User Ids to be excluded from the reply Tweet.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "in_reply_to_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "additionalProperties" : false + }, + "reply_settings" : { + "type" : "string", + "description" : "Settings to indicate who can reply to the Tweet.", + "enum" : [ + "following", + "mentionedUsers", + "subscribers" + ] + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" + } + }, + "additionalProperties" : false + }, + "TweetCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "id", + "text" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "TweetDeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "deleted" + ], + "properties" : { + "deleted" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "TweetDropComplianceSchema" : { + "type" : "object", + "required" : [ + "drop" + ], + "properties" : { + "drop" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetEditComplianceObjectSchema" : { + "type" : "object", + "required" : [ + "tweet", + "event_at", + "initial_tweet_id", + "edit_tweet_ids" + ], + "properties" : { + "edit_tweet_ids" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "initial_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + } + } + }, + "TweetEditComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet_edit" + ], + "properties" : { + "tweet_edit" : { + "$ref" : "#/components/schemas/TweetEditComplianceObjectSchema" + } + } + }, + "TweetHideRequest" : { + "type" : "object", + "required" : [ + "hidden" + ], + "properties" : { + "hidden" : { + "type" : "boolean" + } + } + }, + "TweetHideResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "hidden" : { + "type" : "boolean" + } + } + } + } + }, + "TweetId" : { + "type" : "string", + "description" : "Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1346889436626259968" + }, + "TweetLabelData" : { + "description" : "Tweet label data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/TweetNoticeSchema" + }, + { + "$ref" : "#/components/schemas/TweetUnviewableSchema" + } + ] + }, + "TweetLabelStreamResponse" : { + "description" : "Tweet label stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Tweet Label event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/TweetLabelData" + } + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + ] + }, + "TweetNotice" : { + "type" : "object", + "required" : [ + "tweet", + "event_type", + "event_at", + "application" + ], + "properties" : { + "application" : { + "type" : "string", + "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", + "example" : "apply" + }, + "details" : { + "type" : "string", + "description" : "Information shown on the Tweet label" + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "event_type" : { + "type" : "string", + "description" : "The type of label on the Tweet", + "example" : "misleading" + }, + "extended_details_url" : { + "type" : "string", + "description" : "Link to more information about this kind of label" + }, + "label_title" : { + "type" : "string", + "description" : "Title/header of the Tweet label" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + } + } + }, + "TweetNoticeSchema" : { + "type" : "object", + "required" : [ + "public_tweet_notice" + ], + "properties" : { + "public_tweet_notice" : { + "$ref" : "#/components/schemas/TweetNotice" + } + } + }, + "TweetTakedownComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet", + "withheld_in_countries", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + }, + "withheld_in_countries" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CountryCode" + } + } + } + }, + "TweetText" : { + "type" : "string", + "description" : "The content of the Tweet.", + "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" + }, + "TweetUndropComplianceSchema" : { + "type" : "object", + "required" : [ + "undrop" + ], + "properties" : { + "undrop" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetUnviewable" : { + "type" : "object", + "required" : [ + "tweet", + "event_at", + "application" + ], + "properties" : { + "application" : { + "type" : "string", + "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", + "example" : "apply" + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + } + } + }, + "TweetUnviewableSchema" : { + "type" : "object", + "required" : [ + "public_tweet_unviewable" + ], + "properties" : { + "public_tweet_unviewable" : { + "$ref" : "#/components/schemas/TweetUnviewable" + } + } + }, + "TweetWithheld" : { + "type" : "object", + "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", + "required" : [ + "copyright", + "country_codes" + ], + "properties" : { + "copyright" : { + "type" : "boolean", + "description" : "Indicates if the content is being withheld for on the basis of copyright infringement." + }, + "country_codes" : { + "type" : "array", + "description" : "Provides a list of countries where this content is not available.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "$ref" : "#/components/schemas/CountryCode" + } + }, + "scope" : { + "type" : "string", + "description" : "Indicates whether the content being withheld is the `tweet` or a `user`.", + "enum" : [ + "tweet", + "user" + ] + } + } + }, + "TweetWithheldComplianceSchema" : { + "type" : "object", + "required" : [ + "withheld" + ], + "properties" : { + "withheld" : { + "$ref" : "#/components/schemas/TweetTakedownComplianceSchema" + } + } + }, + "UnlikeComplianceSchema" : { + "type" : "object", + "required" : [ + "favorite", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "favorite" : { + "type" : "object", + "required" : [ + "id", + "user_id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + } + } + }, + "UnsupportedAuthenticationProblem" : { + "description" : "A problem that indicates that the authentication used is not supported.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "UploadExpiration" : { + "type" : "string", + "description" : "Expiration time of the upload URL.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "UploadUrl" : { + "type" : "string", + "description" : "URL to which the user will upload their Tweet or user IDs.", + "format" : "uri" + }, + "Url" : { + "type" : "string", + "description" : "A validly formatted URL.", + "format" : "uri", + "example" : "https://developer.twitter.com/en/docs/twitter-api" + }, + "UrlEntity" : { + "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/UrlFields" + } + ] + }, + "UrlEntityDm" : { + "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/UrlFields" + } + ] + }, + "UrlFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a URL.", + "required" : [ + "url" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the URL landing page.", + "example" : "This is a description of the website." + }, + "display_url" : { + "type" : "string", + "description" : "The URL as displayed in the X client.", + "example" : "twittercommunity.com/t/introducing-…" + }, + "expanded_url" : { + "$ref" : "#/components/schemas/Url" + }, + "images" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlImage" + } + }, + "media_key" : { + "$ref" : "#/components/schemas/MediaKey" + }, + "status" : { + "$ref" : "#/components/schemas/HttpStatusCode" + }, + "title" : { + "type" : "string", + "description" : "Title of the page the URL points to.", + "example" : "Introducing the v2 follow lookup endpoints" + }, + "unwound_url" : { + "type" : "string", + "description" : "Fully resolved url.", + "format" : "uri", + "example" : "https://twittercommunity.com/t/introducing-the-v2-follow-lookup-endpoints/147118" + }, + "url" : { + "$ref" : "#/components/schemas/Url" + } + } + }, + "UrlImage" : { + "type" : "object", + "description" : "Represent the information for the URL image.", + "properties" : { + "height" : { + "$ref" : "#/components/schemas/MediaHeight" + }, + "url" : { + "$ref" : "#/components/schemas/Url" + }, + "width" : { + "$ref" : "#/components/schemas/MediaWidth" + } + } + }, + "Usage" : { + "type" : "object", + "description" : "Usage per client app", + "properties" : { + "cap_reset_day" : { + "type" : "integer", + "description" : "Number of days left for the Tweet cap to reset", + "format" : "int32" + }, + "daily_client_app_usage" : { + "type" : "array", + "description" : "The daily usage breakdown for each Client Application a project", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ClientAppUsage" + } + }, + "daily_project_usage" : { + "type" : "object", + "description" : "The daily usage breakdown for a project", + "properties" : { + "project_id" : { + "type" : "integer", + "description" : "The unique identifier for this project", + "format" : "int32" + }, + "usage" : { + "type" : "array", + "description" : "The usage value", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UsageFields" + } + } + } + }, + "project_cap" : { + "type" : "integer", + "description" : "Total number of Posts that can be read in this project per month", + "format" : "int32" + }, + "project_id" : { + "type" : "string", + "description" : "The unique identifier for this project", + "format" : "^[0-9]{1,19}$" + }, + "project_usage" : { + "type" : "integer", + "description" : "The number of Posts read in this project", + "format" : "int32" + } + } + }, + "UsageCapExceededProblem" : { + "description" : "A problem that indicates that a usage cap has been exceeded.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "period" : { + "type" : "string", + "enum" : [ + "Daily", + "Monthly" + ] + }, + "scope" : { + "type" : "string", + "enum" : [ + "Account", + "Product" + ] + } + } + } + ] + }, + "UsageFields" : { + "type" : "object", + "description" : "Represents the data for Usage", + "properties" : { + "date" : { + "type" : "string", + "description" : "The time period for the usage", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "usage" : { + "type" : "integer", + "description" : "The usage value", + "format" : "int32" + } + } + }, + "User" : { + "type" : "object", + "description" : "The X User object.", + "required" : [ + "id", + "name", + "username" + ], + "properties" : { + "connection_status" : { + "type" : "array", + "description" : "Returns detailed information about the relationship between two users.", + "minItems" : 0, + "items" : { + "type" : "string", + "description" : "Type of connection between users.", + "enum" : [ + "follow_request_received", + "follow_request_sent", + "blocking", + "followed_by", + "following", + "muting" + ] + } + }, + "created_at" : { + "type" : "string", + "description" : "Creation time of this User.", + "format" : "date-time" + }, + "description" : { + "type" : "string", + "description" : "The text of this User's profile description (also known as bio), if the User provided one." + }, + "entities" : { + "type" : "object", + "description" : "A list of metadata found in the User's profile description.", + "properties" : { + "description" : { + "$ref" : "#/components/schemas/FullTextEntities" + }, + "url" : { + "type" : "object", + "description" : "Expanded details for the URL specified in the User's profile, with start and end indices.", + "properties" : { + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" + } + } + } + } + } + }, + "id" : { + "$ref" : "#/components/schemas/UserId" + }, + "location" : { + "type" : "string", + "description" : "The location specified in the User's profile, if the User provided one. As this is a freeform value, it may not indicate a valid location, but it may be fuzzily evaluated when performing searches with location queries." + }, + "most_recent_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "name" : { + "type" : "string", + "description" : "The friendly name of this User, as shown on their profile." + }, + "pinned_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "profile_image_url" : { + "type" : "string", + "description" : "The URL to the profile image for this User.", + "format" : "uri" + }, + "protected" : { + "type" : "boolean", + "description" : "Indicates if this User has chosen to protect their Posts (in other words, if this User's Posts are private)." + }, + "public_metrics" : { + "type" : "object", + "description" : "A list of metrics for this User.", + "required" : [ + "followers_count", + "following_count", + "tweet_count", + "listed_count" + ], + "properties" : { + "followers_count" : { + "type" : "integer", + "description" : "Number of Users who are following this User." + }, + "following_count" : { + "type" : "integer", + "description" : "Number of Users this User is following." + }, + "like_count" : { + "type" : "integer", + "description" : "The number of likes created by this User." + }, + "listed_count" : { + "type" : "integer", + "description" : "The number of lists that include this User." + }, + "tweet_count" : { + "type" : "integer", + "description" : "The number of Posts (including Retweets) posted by this User." + } + } + }, + "receives_your_dm" : { + "type" : "boolean", + "description" : "Indicates if you can send a DM to this User" + }, + "subscription_type" : { + "type" : "string", + "description" : "The X Blue subscription type of the user, eg: Basic, Premium, PremiumPlus or None.", + "enum" : [ + "Basic", + "Premium", + "PremiumPlus", + "None" + ] + }, + "url" : { + "type" : "string", + "description" : "The URL specified in the User's profile." + }, + "username" : { + "$ref" : "#/components/schemas/UserName" + }, + "verified" : { + "type" : "boolean", + "description" : "Indicate if this User is a verified X User." + }, + "verified_type" : { + "type" : "string", + "description" : "The X Blue verified type of the user, eg: blue, government, business or none.", + "enum" : [ + "blue", + "government", + "business", + "none" + ] + }, + "withheld" : { + "$ref" : "#/components/schemas/UserWithheld" + } + }, + "example" : { + "created_at" : "2013-12-14T04:35:55Z", + "id" : "2244994945", + "name" : "X Dev", + "protected" : false, + "username" : "TwitterDev" + } + }, + "UserComplianceData" : { + "description" : "User compliance data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/UserProtectComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUnprotectComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserDeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUndeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserSuspendComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUnsuspendComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserWithheldComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserScrubGeoSchema" + }, + { + "$ref" : "#/components/schemas/UserProfileModificationComplianceSchema" + } + ] + }, + "UserComplianceSchema" : { + "type" : "object", + "required" : [ + "user", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + } + } + } + } + }, + "UserComplianceStreamResponse" : { + "description" : "User compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "User compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/UserComplianceData" + } + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + ] + }, + "UserDeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "user_delete" + ], + "properties" : { + "user_delete" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserId" : { + "type" : "string", + "description" : "Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", + "pattern" : "^[0-9]{1,19}$", + "example" : "2244994945" + }, + "UserIdMatchesAuthenticatedUser" : { + "type" : "string", + "description" : "Unique identifier of this User. The value must be the same as the authenticated user.", + "example" : "2244994945" + }, + "UserName" : { + "type" : "string", + "description" : "The X handle (screen name) of this user.", + "pattern" : "^[A-Za-z0-9_]{1,15}$" + }, + "UserProfileModificationComplianceSchema" : { + "type" : "object", + "required" : [ + "user_profile_modification" + ], + "properties" : { + "user_profile_modification" : { + "$ref" : "#/components/schemas/UserProfileModificationObjectSchema" + } + } + }, + "UserProfileModificationObjectSchema" : { + "type" : "object", + "required" : [ + "user", + "profile_field", + "new_value", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "new_value" : { + "type" : "string" + }, + "profile_field" : { + "type" : "string" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + } + } + } + } + }, + "UserProtectComplianceSchema" : { + "type" : "object", + "required" : [ + "user_protect" + ], + "properties" : { + "user_protect" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserScrubGeoObjectSchema" : { + "type" : "object", + "required" : [ + "user", + "up_to_tweet_id", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "up_to_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + } + } + } + } + }, + "UserScrubGeoSchema" : { + "type" : "object", + "required" : [ + "scrub_geo" + ], + "properties" : { + "scrub_geo" : { + "$ref" : "#/components/schemas/UserScrubGeoObjectSchema" + } + } + }, + "UserSearchQuery" : { + "type" : "string", + "description" : "The the search string by which to query for users.", + "pattern" : "^[A-Za-z0-9_]{1,32}$" + }, + "UserSuspendComplianceSchema" : { + "type" : "object", + "required" : [ + "user_suspend" + ], + "properties" : { + "user_suspend" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserTakedownComplianceSchema" : { + "type" : "object", + "required" : [ + "user", + "withheld_in_countries", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "withheld_in_countries" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CountryCode" + } + } + } + }, + "UserUndeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "user_undelete" + ], + "properties" : { + "user_undelete" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserUnprotectComplianceSchema" : { + "type" : "object", + "required" : [ + "user_unprotect" + ], + "properties" : { + "user_unprotect" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserUnsuspendComplianceSchema" : { + "type" : "object", + "required" : [ + "user_unsuspend" + ], + "properties" : { + "user_unsuspend" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserWithheld" : { + "type" : "object", + "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", + "required" : [ + "country_codes" + ], + "properties" : { + "country_codes" : { + "type" : "array", + "description" : "Provides a list of countries where this content is not available.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "$ref" : "#/components/schemas/CountryCode" + } + }, + "scope" : { + "type" : "string", + "description" : "Indicates that the content being withheld is a `user`.", + "enum" : [ + "user" + ] + } + } + }, + "UserWithheldComplianceSchema" : { + "type" : "object", + "required" : [ + "user_withheld" + ], + "properties" : { + "user_withheld" : { + "$ref" : "#/components/schemas/UserTakedownComplianceSchema" + } + } + }, + "UsersFollowingCreateRequest" : { + "type" : "object", + "required" : [ + "target_user_id" + ], + "properties" : { + "target_user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "UsersFollowingCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" + }, + "pending_follow" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersFollowingDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersLikesCreateRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + }, + "UsersLikesCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "liked" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersLikesDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "liked" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersRetweetsCreateRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "additionalProperties" : false + }, + "UsersRetweetsCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "retweeted" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersRetweetsDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "retweeted" : { + "type" : "boolean" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "Variant" : { + "type" : "object", + "properties" : { + "bit_rate" : { + "type" : "integer", + "description" : "The bit rate of the media." + }, + "content_type" : { + "type" : "string", + "description" : "The content type of the media." + }, + "url" : { + "type" : "string", + "description" : "The url to the media.", + "format" : "uri" + } + } + }, + "Variants" : { + "type" : "array", + "description" : "An array of all available variants of the media.", + "items" : { + "$ref" : "#/components/schemas/Variant" + } + }, + "Video" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "duration_ms" : { + "type" : "integer" + }, + "non_public_metrics" : { + "type" : "object", + "description" : "Nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" + } + } + }, + "organic_metrics" : { + "type" : "object", + "description" : "Organic nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" + }, + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" + } + } + }, + "preview_image_url" : { + "type" : "string", + "format" : "uri" + }, + "promoted_metrics" : { + "type" : "object", + "description" : "Promoted nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" + }, + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" + } + } + }, + "public_metrics" : { + "type" : "object", + "description" : "Engagement metrics for the Media at the time of the request.", + "properties" : { + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" + } + } + }, + "variants" : { + "$ref" : "#/components/schemas/Variants" + } + } + } + ] + } + }, + "parameters" : { + "ComplianceJobFieldsParameter" : { + "name" : "compliance_job.fields", + "in" : "query", + "description" : "A comma separated list of ComplianceJob fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a ComplianceJob object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "created_at", + "download_expires_at", + "download_url", + "id", + "name", + "resumable", + "status", + "type", + "upload_expires_at", + "upload_url" + ] + }, + "example" : [ + "created_at", + "download_expires_at", + "download_url", + "id", + "name", + "resumable", + "status", + "type", + "upload_expires_at", + "upload_url" + ] + }, + "explode" : false, + "style" : "form" + }, + "DmConversationFieldsParameter" : { + "name" : "dm_conversation.fields", + "in" : "query", + "description" : "A comma separated list of DmConversation fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a DmConversation object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "id" + ] + }, + "example" : [ + "id" + ] + }, + "explode" : false, + "style" : "form" + }, + "DmEventExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [DmEvent](#DmEvent) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "attachments.media_keys", + "participant_ids", + "referenced_tweets.id", + "sender_id" + ] + }, + "example" : [ + "attachments.media_keys", + "participant_ids", + "referenced_tweets.id", + "sender_id" + ] + }, + "explode" : false, + "style" : "form" + }, + "DmEventFieldsParameter" : { + "name" : "dm_event.fields", + "in" : "query", + "description" : "A comma separated list of DmEvent fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a DmEvent object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "attachments", + "created_at", + "dm_conversation_id", + "entities", + "event_type", + "id", + "participant_ids", + "referenced_tweets", + "sender_id", + "text" + ] + }, + "example" : [ + "attachments", + "created_at", + "dm_conversation_id", + "entities", + "event_type", + "id", + "participant_ids", + "referenced_tweets", + "sender_id", + "text" + ] + }, + "explode" : false, + "style" : "form" + }, + "LikeExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Like](#Like) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "liked_tweet_id" + ] + }, + "example" : [ + "liked_tweet_id" + ] + }, + "explode" : false, + "style" : "form" + }, + "LikeFieldsParameter" : { + "name" : "like.fields", + "in" : "query", + "description" : "A comma separated list of Like fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Like object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "created_at", + "id", + "liked_tweet_id", + "timestamp_ms" + ] + }, + "example" : [ + "created_at", + "id", + "liked_tweet_id", + "timestamp_ms" + ] + }, + "explode" : false, + "style" : "form" + }, + "ListExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [List](#List) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "owner_id" + ] + }, + "example" : [ + "owner_id" + ] + }, + "explode" : false, + "style" : "form" + }, + "ListFieldsParameter" : { + "name" : "list.fields", + "in" : "query", + "description" : "A comma separated list of List fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a List object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "created_at", + "description", + "follower_count", + "id", + "member_count", + "name", + "owner_id", + "private" + ] + }, + "example" : [ + "created_at", + "description", + "follower_count", + "id", + "member_count", + "name", + "owner_id", + "private" + ] + }, + "explode" : false, + "style" : "form" + }, + "MediaFieldsParameter" : { + "name" : "media.fields", + "in" : "query", + "description" : "A comma separated list of Media fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Media object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "alt_text", + "duration_ms", + "height", + "media_key", + "non_public_metrics", + "organic_metrics", + "preview_image_url", + "promoted_metrics", + "public_metrics", + "type", + "url", + "variants", + "width" + ] + }, + "example" : [ + "alt_text", + "duration_ms", + "height", + "media_key", + "non_public_metrics", + "organic_metrics", + "preview_image_url", + "promoted_metrics", + "public_metrics", + "type", + "url", + "variants", + "width" + ] + }, + "explode" : false, + "style" : "form" + }, + "PlaceFieldsParameter" : { + "name" : "place.fields", + "in" : "query", + "description" : "A comma separated list of Place fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Place object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "contained_within", + "country", + "country_code", + "full_name", + "geo", + "id", + "name", + "place_type" + ] + }, + "example" : [ + "contained_within", + "country", + "country_code", + "full_name", + "geo", + "id", + "name", + "place_type" + ] + }, + "explode" : false, + "style" : "form" + }, + "PollFieldsParameter" : { + "name" : "poll.fields", + "in" : "query", + "description" : "A comma separated list of Poll fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Poll object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "duration_minutes", + "end_datetime", + "id", + "options", + "voting_status" + ] + }, + "example" : [ + "duration_minutes", + "end_datetime", + "id", + "options", + "voting_status" + ] + }, + "explode" : false, + "style" : "form" + }, + "RulesCountFieldsParameter" : { + "name" : "rules_count.fields", + "in" : "query", + "description" : "A comma separated list of RulesCount fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a RulesCount object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "all_project_client_apps", + "cap_per_client_app", + "cap_per_project", + "client_app_rules_count", + "project_rules_count" + ] + }, + "example" : [ + "all_project_client_apps", + "cap_per_client_app", + "cap_per_project", + "client_app_rules_count", + "project_rules_count" + ] + }, + "explode" : false, + "style" : "form" + }, + "SearchCountFieldsParameter" : { + "name" : "search_count.fields", + "in" : "query", + "description" : "A comma separated list of SearchCount fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a SearchCount object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "end", + "start", + "tweet_count" + ] + }, + "example" : [ + "end", + "start", + "tweet_count" + ] + }, + "explode" : false, + "style" : "form" + }, + "SpaceExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Space](#Space) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "creator_id", + "host_ids", + "invited_user_ids", + "speaker_ids", + "topic_ids" + ] + }, + "example" : [ + "creator_id", + "host_ids", + "invited_user_ids", + "speaker_ids", + "topic_ids" + ] + }, + "explode" : false, + "style" : "form" + }, + "SpaceFieldsParameter" : { + "name" : "space.fields", + "in" : "query", + "description" : "A comma separated list of Space fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Space object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "created_at", + "creator_id", + "ended_at", + "host_ids", + "id", + "invited_user_ids", + "is_ticketed", + "lang", + "participant_count", + "scheduled_start", + "speaker_ids", + "started_at", + "state", + "subscriber_count", + "title", + "topic_ids", + "updated_at" + ] + }, + "example" : [ + "created_at", + "creator_id", + "ended_at", + "host_ids", + "id", + "invited_user_ids", + "is_ticketed", + "lang", + "participant_count", + "scheduled_start", + "speaker_ids", + "started_at", + "state", + "subscriber_count", + "title", + "topic_ids", + "updated_at" + ] + }, + "explode" : false, + "style" : "form" + }, + "TopicFieldsParameter" : { + "name" : "topic.fields", + "in" : "query", + "description" : "A comma separated list of Topic fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Topic object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "description", + "id", + "name" + ] + }, + "example" : [ + "description", + "id", + "name" + ] + }, + "explode" : false, + "style" : "form" + }, + "TrendFieldsParameter" : { + "name" : "trend.fields", + "in" : "query", + "description" : "A comma separated list of Trend fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Trend object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "trend_name", + "tweet_count" + ] + }, + "example" : [ + "trend_name", + "tweet_count" + ] + }, + "explode" : false, + "style" : "form" + }, + "TweetExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Tweet](#Tweet) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "attachments.media_keys", + "attachments.media_source_tweet", + "attachments.poll_ids", + "author_id", + "edit_history_tweet_ids", + "entities.mentions.username", + "geo.place_id", + "in_reply_to_user_id", + "entities.note.mentions.username", + "referenced_tweets.id", + "referenced_tweets.id.author_id", + "author_screen_name" + ] + }, + "example" : [ + "attachments.media_keys", + "attachments.media_source_tweet", + "attachments.poll_ids", + "author_id", + "edit_history_tweet_ids", + "entities.mentions.username", + "geo.place_id", + "in_reply_to_user_id", + "entities.note.mentions.username", + "referenced_tweets.id", + "referenced_tweets.id.author_id", + "author_screen_name" + ] + }, + "explode" : false, + "style" : "form" + }, + "TweetFieldsParameter" : { + "name" : "tweet.fields", + "in" : "query", + "description" : "A comma separated list of Tweet fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Tweet object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "attachments", + "author_id", + "card_uri", + "context_annotations", + "conversation_id", + "created_at", + "edit_controls", + "edit_history_tweet_ids", + "entities", + "geo", + "id", + "in_reply_to_user_id", + "lang", + "non_public_metrics", + "note_tweet", + "organic_metrics", + "possibly_sensitive", + "promoted_metrics", + "public_metrics", + "referenced_tweets", + "reply_settings", + "scopes", + "source", + "text", + "username", + "withheld" + ] + }, + "example" : [ + "attachments", + "author_id", + "card_uri", + "context_annotations", + "conversation_id", + "created_at", + "edit_controls", + "edit_history_tweet_ids", + "entities", + "geo", + "id", + "in_reply_to_user_id", + "lang", + "non_public_metrics", + "note_tweet", + "organic_metrics", + "possibly_sensitive", + "promoted_metrics", + "public_metrics", + "referenced_tweets", + "reply_settings", + "scopes", + "source", + "text", + "username", + "withheld" + ] + }, + "explode" : false, + "style" : "form" + }, + "UsageFieldsParameter" : { + "name" : "usage.fields", + "in" : "query", + "description" : "A comma separated list of Usage fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Usage object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "cap_reset_day", + "daily_client_app_usage", + "daily_project_usage", + "project_cap", + "project_id", + "project_usage" + ] + }, + "example" : [ + "cap_reset_day", + "daily_client_app_usage", + "daily_project_usage", + "project_cap", + "project_id", + "project_usage" + ] + }, + "explode" : false, + "style" : "form" + }, + "UserExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [User](#User) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "most_recent_tweet_id", + "pinned_tweet_id" + ] + }, + "example" : [ + "most_recent_tweet_id", + "pinned_tweet_id" + ] + }, + "explode" : false, + "style" : "form" + }, + "UserFieldsParameter" : { + "name" : "user.fields", + "in" : "query", + "description" : "A comma separated list of User fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a User object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "connection_status", + "created_at", + "description", + "entities", + "id", + "location", + "most_recent_tweet_id", + "name", + "pinned_tweet_id", + "profile_image_url", + "protected", + "public_metrics", + "receives_your_dm", + "subscription_type", + "url", + "username", + "verified", + "verified_type", + "withheld" + ] + }, + "example" : [ + "connection_status", + "created_at", + "description", + "entities", + "id", + "location", + "most_recent_tweet_id", + "name", + "pinned_tweet_id", + "profile_image_url", + "protected", + "public_metrics", + "receives_your_dm", + "subscription_type", + "url", + "username", + "verified", + "verified_type", + "withheld" + ] + }, + "explode" : false, + "style" : "form" + } + } + } + } \ No newline at end of file From 093febb9ea804522dacc493bf153dfb02056c43d Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Wed, 19 Jun 2024 16:31:04 +0530 Subject: [PATCH 02/10] update the generated files with license --- ballerina/client.bal | 16 ++++++++++++++++ ballerina/types.bal | 16 ++++++++++++++++ ballerina/utils.bal | 16 ++++++++++++++++ docs/{ => spec}/twitter_open_api_spec.json | 0 4 files changed, 48 insertions(+) rename docs/{ => spec}/twitter_open_api_spec.json (100%) diff --git a/ballerina/client.bal b/ballerina/client.bal index 93c8c77..ab4a853 100644 --- a/ballerina/client.bal +++ b/ballerina/client.bal @@ -1,6 +1,22 @@ // AUTO-GENERATED FILE. DO NOT MODIFY. // This file is auto-generated by the Ballerina OpenAPI tool. +// Copyright (c) 2024, WSO2 LLC. (http://www.wso2.com). +// +// WSO2 LLC. licenses this file to you under the Apache License, +// Version 2.0 (the "License"); you may not use this file except +// in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + import ballerina/http; # Twitter API v2 available endpoints diff --git a/ballerina/types.bal b/ballerina/types.bal index 3bba3ad..d565777 100644 --- a/ballerina/types.bal +++ b/ballerina/types.bal @@ -1,6 +1,22 @@ // AUTO-GENERATED FILE. DO NOT MODIFY. // This file is auto-generated by the Ballerina OpenAPI tool. +// Copyright (c) 2024, WSO2 LLC. (http://www.wso2.com). +// +// WSO2 LLC. licenses this file to you under the Apache License, +// Version 2.0 (the "License"); you may not use this file except +// in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + import ballerina/constraint; import ballerina/http; diff --git a/ballerina/utils.bal b/ballerina/utils.bal index 8fb8e44..1337438 100644 --- a/ballerina/utils.bal +++ b/ballerina/utils.bal @@ -1,6 +1,22 @@ // AUTO-GENERATED FILE. DO NOT MODIFY. // This file is auto-generated by the Ballerina OpenAPI tool. +// Copyright (c) 2024, WSO2 LLC. (http://www.wso2.com). +// +// WSO2 LLC. licenses this file to you under the Apache License, +// Version 2.0 (the "License"); you may not use this file except +// in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + import ballerina/url; type SimpleBasicType string|boolean|int|float|decimal; diff --git a/docs/twitter_open_api_spec.json b/docs/spec/twitter_open_api_spec.json similarity index 100% rename from docs/twitter_open_api_spec.json rename to docs/spec/twitter_open_api_spec.json From e4c63efac0270f492c044d30cbdbd53205d7be9a Mon Sep 17 00:00:00 2001 From: ayeshLK Date: Tue, 25 Jun 2024 12:12:05 +0530 Subject: [PATCH 03/10] [Automated] Update the toml files --- ballerina/Ballerina.toml | 4 +- ballerina/Dependencies.toml | 261 +++++++++++++++++++++++++++++++++++- 2 files changed, 261 insertions(+), 4 deletions(-) diff --git a/ballerina/Ballerina.toml b/ballerina/Ballerina.toml index f5ccc9c..d606413 100644 --- a/ballerina/Ballerina.toml +++ b/ballerina/Ballerina.toml @@ -1,8 +1,8 @@ [package] -distribution = "2201.8.6" +distribution = "2201.9.0" org = "ballerinax" name = "twitter" -version = "0.1.0" +version = "4.0.0" license = ["Apache-2.0"] authors = ["Ballerina"] keywords = ["Marketing/Social Media Accounts", "Cost/Freemium"] diff --git a/ballerina/Dependencies.toml b/ballerina/Dependencies.toml index 6bb0dd3..17301a6 100644 --- a/ballerina/Dependencies.toml +++ b/ballerina/Dependencies.toml @@ -5,13 +5,230 @@ [ballerina] dependencies-toml-version = "2" -distribution-version = "2201.8.6" +distribution-version = "2201.9.0" + +[[package]] +org = "ballerina" +name = "auth" +version = "2.11.0" +dependencies = [ + {org = "ballerina", name = "crypto"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.array"}, + {org = "ballerina", name = "lang.string"}, + {org = "ballerina", name = "log"} +] + +[[package]] +org = "ballerina" +name = "cache" +version = "3.8.0" +dependencies = [ + {org = "ballerina", name = "constraint"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "task"}, + {org = "ballerina", name = "time"} +] + +[[package]] +org = "ballerina" +name = "constraint" +version = "1.5.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] +modules = [ + {org = "ballerina", packageName = "constraint", moduleName = "constraint"} +] + +[[package]] +org = "ballerina" +name = "crypto" +version = "2.7.2" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "time"} +] + +[[package]] +org = "ballerina" +name = "file" +version = "1.9.0" +dependencies = [ + {org = "ballerina", name = "io"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "os"}, + {org = "ballerina", name = "time"} +] + +[[package]] +org = "ballerina" +name = "http" +version = "2.11.2" +dependencies = [ + {org = "ballerina", name = "auth"}, + {org = "ballerina", name = "cache"}, + {org = "ballerina", name = "constraint"}, + {org = "ballerina", name = "crypto"}, + {org = "ballerina", name = "file"}, + {org = "ballerina", name = "io"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "jwt"}, + {org = "ballerina", name = "lang.array"}, + {org = "ballerina", name = "lang.decimal"}, + {org = "ballerina", name = "lang.int"}, + {org = "ballerina", name = "lang.regexp"}, + {org = "ballerina", name = "lang.runtime"}, + {org = "ballerina", name = "lang.string"}, + {org = "ballerina", name = "lang.value"}, + {org = "ballerina", name = "log"}, + {org = "ballerina", name = "mime"}, + {org = "ballerina", name = "oauth2"}, + {org = "ballerina", name = "observe"}, + {org = "ballerina", name = "time"}, + {org = "ballerina", name = "url"} +] +modules = [ + {org = "ballerina", packageName = "http", moduleName = "http"}, + {org = "ballerina", packageName = "http", moduleName = "http.httpscerr"} +] + +[[package]] +org = "ballerina" +name = "io" +version = "1.6.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.value"} +] [[package]] org = "ballerina" name = "jballerina.java" version = "0.0.0" +[[package]] +org = "ballerina" +name = "jwt" +version = "2.12.1" +dependencies = [ + {org = "ballerina", name = "cache"}, + {org = "ballerina", name = "crypto"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.int"}, + {org = "ballerina", name = "lang.string"}, + {org = "ballerina", name = "log"}, + {org = "ballerina", name = "time"} +] + +[[package]] +org = "ballerina" +name = "lang.__internal" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.object"} +] + +[[package]] +org = "ballerina" +name = "lang.array" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.__internal"} +] + +[[package]] +org = "ballerina" +name = "lang.decimal" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "lang.int" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.__internal"}, + {org = "ballerina", name = "lang.object"} +] + +[[package]] +org = "ballerina" +name = "lang.object" +version = "0.0.0" + +[[package]] +org = "ballerina" +name = "lang.regexp" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "lang.runtime" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "lang.string" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.regexp"} +] + +[[package]] +org = "ballerina" +name = "lang.value" +version = "0.0.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "log" +version = "2.9.0" +dependencies = [ + {org = "ballerina", name = "io"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.value"}, + {org = "ballerina", name = "observe"} +] + +[[package]] +org = "ballerina" +name = "mime" +version = "2.9.0" +dependencies = [ + {org = "ballerina", name = "io"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "lang.int"} +] + +[[package]] +org = "ballerina" +name = "oauth2" +version = "2.11.0" +dependencies = [ + {org = "ballerina", name = "cache"}, + {org = "ballerina", name = "crypto"}, + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "log"}, + {org = "ballerina", name = "time"}, + {org = "ballerina", name = "url"} +] + [[package]] org = "ballerina" name = "observe" @@ -20,6 +237,43 @@ dependencies = [ {org = "ballerina", name = "jballerina.java"} ] +[[package]] +org = "ballerina" +name = "os" +version = "1.8.0" +dependencies = [ + {org = "ballerina", name = "io"}, + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "task" +version = "2.5.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"}, + {org = "ballerina", name = "time"} +] + +[[package]] +org = "ballerina" +name = "time" +version = "2.4.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] + +[[package]] +org = "ballerina" +name = "url" +version = "2.4.0" +dependencies = [ + {org = "ballerina", name = "jballerina.java"} +] +modules = [ + {org = "ballerina", packageName = "url", moduleName = "url"} +] + [[package]] org = "ballerinai" name = "observe" @@ -35,8 +289,11 @@ modules = [ [[package]] org = "ballerinax" name = "twitter" -version = "0.1.0" +version = "4.0.0" dependencies = [ + {org = "ballerina", name = "constraint"}, + {org = "ballerina", name = "http"}, + {org = "ballerina", name = "url"}, {org = "ballerinai", name = "observe"} ] modules = [ From 1e3224e08c491dee97f475cb90766a239f7897ff Mon Sep 17 00:00:00 2001 From: ayeshLK Date: Tue, 25 Jun 2024 12:12:16 +0530 Subject: [PATCH 04/10] Update ballerina distribution version --- build-config/resources/Ballerina.toml | 2 +- gradle.properties | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build-config/resources/Ballerina.toml b/build-config/resources/Ballerina.toml index a6f0aef..34c2c99 100644 --- a/build-config/resources/Ballerina.toml +++ b/build-config/resources/Ballerina.toml @@ -1,5 +1,5 @@ [package] -distribution = "2201.8.6" +distribution = "2201.9.0" org = "ballerinax" name = "twitter" version = "@toml.version@" diff --git a/gradle.properties b/gradle.properties index 6f018a7..c20a9ad 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,4 +10,4 @@ releasePluginVersion=2.8.0 testngVersion=7.6.1 eclipseLsp4jVersion=0.12.0 ballerinaGradlePluginVersion=2.2.4 -ballerinaLangVersion=2201.8.6 +ballerinaLangVersion=2201.9.0 From 23025fa7afd77b93ae5e2108e98b7bab8a7248de Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Tue, 25 Jun 2024 14:43:07 +0530 Subject: [PATCH 05/10] Rename twitter_open_api_spec.json to Standard file name openapi.json --- docs/spec/{twitter_open_api_spec.json => openapi.json} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/spec/{twitter_open_api_spec.json => openapi.json} (100%) diff --git a/docs/spec/twitter_open_api_spec.json b/docs/spec/openapi.json similarity index 100% rename from docs/spec/twitter_open_api_spec.json rename to docs/spec/openapi.json From 25fd0928f8b2604f837a81e5d78a223b015633ec Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Tue, 25 Jun 2024 16:40:19 +0530 Subject: [PATCH 06/10] Add Sanitations.md to the project --- docs/spec/sanitations.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 docs/spec/sanitations.md diff --git a/docs/spec/sanitations.md b/docs/spec/sanitations.md new file mode 100644 index 0000000..bf7f5f2 --- /dev/null +++ b/docs/spec/sanitations.md @@ -0,0 +1,13 @@ +_Authors_: vish-mv , @loshan20011 \ +_Created_: 2024/03/26 \ +_Updated_: 2024/03/26 \ +_Edition_: Swan Lake + +## OpenAPI cli command + +The following command was used to generate the Ballerina client from the OpenAPI specification. The command should be executed from the repository root directory. + +```bash +bal openapi -i docs/spec/openapi.json --mode client --license docs/license.txt -o ballerina +``` +Note: The license year is hardcoded to 2024, change if necessary. From 14419809079d16050e2bdd56876e643b4a012810 Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Tue, 25 Jun 2024 21:54:42 +0530 Subject: [PATCH 07/10] Update sanitations.md with correct author formats Co-authored-by: Nipuna Ransinghe --- docs/spec/sanitations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/spec/sanitations.md b/docs/spec/sanitations.md index bf7f5f2..1e53ef9 100644 --- a/docs/spec/sanitations.md +++ b/docs/spec/sanitations.md @@ -1,4 +1,4 @@ -_Authors_: vish-mv , @loshan20011 \ +_Authors_: @vish-mv @loshan20011 \ _Created_: 2024/03/26 \ _Updated_: 2024/03/26 \ _Edition_: Swan Lake From ce59bd4f7dae45172e0b95909434316bc94e56d8 Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Wed, 26 Jun 2024 15:22:44 +0530 Subject: [PATCH 08/10] Add Sanitations to the OpenApi spec and generate clients via sanitized spec Add Sanitations to the openapi.json spec for improve readability and usability of functions And generate client, util, type bal files Via new spec --- ballerina/client.bal | 754 +- ballerina/types.bal | 332 +- docs/spec/openapi.json | 27532 +++++++++++++++++++-------------------- 3 files changed, 14501 insertions(+), 14117 deletions(-) diff --git a/ballerina/client.bal b/ballerina/client.bal index ab4a853..719b205 100644 --- a/ballerina/client.bal +++ b/ballerina/client.bal @@ -27,7 +27,7 @@ public isolated client class Client { # + config - The configurations to be used when initializing the `connector` # + serviceUrl - URL of the target service # + return - An error if connector initialization failed - public isolated function init(ConnectionConfig config, string serviceUrl = "https://api.twitter.com") returns error? { + public isolated function init(ConnectionConfig config, string serviceUrl = "https://api.twitter.com/2") returns error? { http:ClientConfiguration httpClientConfig = {auth: config.auth, httpVersion: config.httpVersion, timeout: config.timeout, forwarded: config.forwarded, poolConfig: config.poolConfig, compression: config.compression, circuitBreaker: config.circuitBreaker, retryConfig: config.retryConfig, validation: config.validation}; do { if config.http1Settings is ClientHttp1Settings { @@ -55,561 +55,900 @@ public isolated client class Client { return; } - resource isolated function delete '2/dm_events/[DmEventId event_id](map headers = {}) returns DeleteDmResponse|error { - string resourcePath = string `/2/dm_events/${getEncodedUri(event_id)}`; + # Delete Dm + # + # + event_id - The ID of the direct-message event to delete. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete dm_events/[DmEventId event_id](map headers = {}) returns DeleteDmResponse|error { + string resourcePath = string `/dm_events/${getEncodedUri(event_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/lists/[ListId id](map headers = {}) returns ListDeleteResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + # Delete List + # + # + id - The ID of the List to delete. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete lists/[ListId id](map headers = {}) returns ListDeleteResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/lists/[ListId id]/members/[UserId user_id](map headers = {}) returns ListMutateResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}/members/${getEncodedUri(user_id)}`; + # Remove a List member + # + # + id - The ID of the List to remove a member. + # + user_id - The ID of User that will be removed from the List. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete lists/[ListId id]/members/[UserId user_id](map headers = {}) returns ListMutateResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}/members/${getEncodedUri(user_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/tweets/[TweetId id](map headers = {}) returns TweetDeleteResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}`; + # Post delete by Post ID + # + # + id - The ID of the Post to be deleted. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete tweets/[TweetId id](map headers = {}) returns TweetDeleteResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks/[TweetId tweet_id](map headers = {}) returns BookmarkMutationResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks/${getEncodedUri(tweet_id)}`; + # Remove a bookmarked Post + # + # + id - The ID of the authenticated source User whose bookmark is to be removed. + # + tweet_id - The ID of the Post that the source User is removing from bookmarks. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser id]/bookmarks/[TweetId tweet_id](map headers = {}) returns BookmarkMutationResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/bookmarks/${getEncodedUri(tweet_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/followed_lists/[ListId list_id](map headers = {}) returns ListFollowedResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists/${getEncodedUri(list_id)}`; + # Unfollow a List + # + # + id - The ID of the authenticated source User that will unfollow the List. + # + list_id - The ID of the List to unfollow. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser id]/followed_lists/[ListId list_id](map headers = {}) returns ListFollowedResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/followed_lists/${getEncodedUri(list_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/likes/[TweetId tweet_id](map headers = {}) returns UsersLikesDeleteResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/likes/${getEncodedUri(tweet_id)}`; + # Causes the User (in the path) to unlike the specified Post + # + # + id - The ID of the authenticated source User that is requesting to unlike the Post. + # + tweet_id - The ID of the Post that the User is requesting to unlike. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser id]/likes/[TweetId tweet_id](map headers = {}) returns UsersLikesDeleteResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/likes/${getEncodedUri(tweet_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists/[ListId list_id](map headers = {}) returns ListUnpinResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists/${getEncodedUri(list_id)}`; + # Unpin a List + # + # + id - The ID of the authenticated source User for whom to return results. + # + list_id - The ID of the List to unpin. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser id]/pinned_lists/[ListId list_id](map headers = {}) returns ListUnpinResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/pinned_lists/${getEncodedUri(list_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser id]/retweets/[TweetId source_tweet_id](map headers = {}) returns UsersRetweetsDeleteResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/retweets/${getEncodedUri(source_tweet_id)}`; + # Causes the User (in the path) to unretweet the specified Post + # + # + id - The ID of the authenticated source User that is requesting to repost the Post. + # + source_tweet_id - The ID of the Post that the User is requesting to unretweet. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser id]/retweets/[TweetId source_tweet_id](map headers = {}) returns UsersRetweetsDeleteResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/retweets/${getEncodedUri(source_tweet_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser source_user_id]/following/[UserId target_user_id](map headers = {}) returns UsersFollowingDeleteResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(source_user_id)}/following/${getEncodedUri(target_user_id)}`; + # Unfollow User + # + # + source_user_id - The ID of the authenticated source User that is requesting to unfollow the target User. + # + target_user_id - The ID of the User that the source User is requesting to unfollow. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser source_user_id]/following/[UserId target_user_id](map headers = {}) returns UsersFollowingDeleteResponse|error { + string resourcePath = string `/users/${getEncodedUri(source_user_id)}/following/${getEncodedUri(target_user_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function delete '2/users/[UserIdMatchesAuthenticatedUser source_user_id]/muting/[UserId target_user_id](map headers = {}) returns MuteUserMutationResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(source_user_id)}/muting/${getEncodedUri(target_user_id)}`; + # Unmute User by User ID + # + # + source_user_id - The ID of the authenticated source User that is requesting to unmute the target User. + # + target_user_id - The ID of the User that the source User is requesting to unmute. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function delete users/[UserIdMatchesAuthenticatedUser source_user_id]/muting/[UserId target_user_id](map headers = {}) returns MuteUserMutationResponse|error { + string resourcePath = string `/users/${getEncodedUri(source_user_id)}/muting/${getEncodedUri(target_user_id)}`; return self.clientEp->delete(resourcePath, headers = headers); } - resource isolated function get '2/compliance/jobs(map headers = {}, *ListBatchComplianceJobsQueries queries) returns Get2ComplianceJobsResponse|error { - string resourcePath = string `/2/compliance/jobs`; + # List Compliance Jobs + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get compliance/jobs(map headers = {}, *ListBatchComplianceJobsQueries queries) returns Get2ComplianceJobsResponse|error { + string resourcePath = string `/compliance/jobs`; map queryParamEncoding = {"compliance_job.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/compliance/jobs/[JobId id](map headers = {}, *GetBatchComplianceJobQueries queries) returns Get2ComplianceJobsIdResponse|error { - string resourcePath = string `/2/compliance/jobs/${getEncodedUri(id)}`; + # Get Compliance Job + # + # + id - The ID of the Compliance Job to retrieve. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get compliance/jobs/[JobId id](map headers = {}, *GetBatchComplianceJobQueries queries) returns Get2ComplianceJobsIdResponse|error { + string resourcePath = string `/compliance/jobs/${getEncodedUri(id)}`; map queryParamEncoding = {"compliance_job.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/dm_conversations/[DmConversationId id]/dm_events(map headers = {}, *GetDmConversationsIdDmEventsQueries queries) returns Get2DmConversationsIdDmEventsResponse|error { - string resourcePath = string `/2/dm_conversations/${getEncodedUri(id)}/dm_events`; + # Get DM Events for a DM Conversation + # + # + id - The DM Conversation ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get dm_conversations/[DmConversationId id]/dm_events(map headers = {}, *GetDmConversationsIdDmEventsQueries queries) returns Get2DmConversationsIdDmEventsResponse|error { + string resourcePath = string `/dm_conversations/${getEncodedUri(id)}/dm_events`; map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/dm_conversations/with/[UserId participant_id]/dm_events(map headers = {}, *GetDmConversationsWithParticipantIdDmEventsQueries queries) returns Get2DmConversationsWithParticipantIdDmEventsResponse|error { - string resourcePath = string `/2/dm_conversations/with/${getEncodedUri(participant_id)}/dm_events`; + # Get DM Events for a DM Conversation + # + # + participant_id - The ID of the participant user for the One to One DM conversation. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get dm_conversations/with/[UserId participant_id]/dm_events(map headers = {}, *GetDmConversationsWithParticipantIdDmEventsQueries queries) returns Get2DmConversationsWithParticipantIdDmEventsResponse|error { + string resourcePath = string `/dm_conversations/with/${getEncodedUri(participant_id)}/dm_events`; map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/dm_events(map headers = {}, *GetDmEventsQueries queries) returns Get2DmEventsResponse|error { - string resourcePath = string `/2/dm_events`; + # Get recent DM Events + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get dm_events(map headers = {}, *GetDmEventsQueries queries) returns Get2DmEventsResponse|error { + string resourcePath = string `/dm_events`; map queryParamEncoding = {"event_types": {style: FORM, explode: false}, "dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/dm_events/[DmEventId event_id](map headers = {}, *GetDmEventsByIdQueries queries) returns Get2DmEventsEventIdResponse|error { - string resourcePath = string `/2/dm_events/${getEncodedUri(event_id)}`; + # Get DM Events by id + # + # + event_id - dm event id. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get dm_events/[DmEventId event_id](map headers = {}, *GetDmEventsByIdQueries queries) returns Get2DmEventsEventIdResponse|error { + string resourcePath = string `/dm_events/${getEncodedUri(event_id)}`; map queryParamEncoding = {"dm_event.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/likes/compliance/'stream(map headers = {}, *GetLikesComplianceStreamQueries queries) returns LikesComplianceStreamResponse|error { - string resourcePath = string `/2/likes/compliance/stream`; + resource isolated function get likes/compliance/'stream(map headers = {}, *GetLikesComplianceStreamQueries queries) returns LikesComplianceStreamResponse|error { + string resourcePath = string `/likes/compliance/stream`; resourcePath = resourcePath + check getPathForQueryParam(queries); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/likes/firehose/'stream(map headers = {}, *LikesFirehoseStreamQueries queries) returns StreamingLikeResponse|error { - string resourcePath = string `/2/likes/firehose/stream`; + resource isolated function get likes/firehose/'stream(map headers = {}, *LikesFirehoseStreamQueries queries) returns StreamingLikeResponse|error { + string resourcePath = string `/likes/firehose/stream`; map queryParamEncoding = {"like.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/likes/sample10/'stream(map headers = {}, *LikesSample10StreamQueries queries) returns StreamingLikeResponse|error { - string resourcePath = string `/2/likes/sample10/stream`; + resource isolated function get likes/sample10/'stream(map headers = {}, *LikesSample10StreamQueries queries) returns StreamingLikeResponse|error { + string resourcePath = string `/likes/sample10/stream`; map queryParamEncoding = {"like.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/lists/[ListId id](map headers = {}, *ListIdGetQueries queries) returns Get2ListsIdResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + # List lookup by List ID. + # + # + id - The ID of the List. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get lists/[ListId id](map headers = {}, *ListIdGetQueries queries) returns Get2ListsIdResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}`; map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/lists/[ListId id]/followers(map headers = {}, *ListGetFollowersQueries queries) returns Get2ListsIdFollowersResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}/followers`; + # Returns User objects that follow a List by the provided List ID + # + # + id - The ID of the List. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get lists/[ListId id]/followers(map headers = {}, *ListGetFollowersQueries queries) returns Get2ListsIdFollowersResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}/followers`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/lists/[ListId id]/members(map headers = {}, *ListGetMembersQueries queries) returns Get2ListsIdMembersResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}/members`; + # Returns User objects that are members of a List by the provided List ID. + # + # + id - The ID of the List. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get lists/[ListId id]/members(map headers = {}, *ListGetMembersQueries queries) returns Get2ListsIdMembersResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}/members`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/lists/[ListId id]/tweets(map headers = {}, *ListsIdTweetsQueries queries) returns Get2ListsIdTweetsResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}/tweets`; + # List Posts timeline by List ID. + # + # + id - The ID of the List. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get lists/[ListId id]/tweets(map headers = {}, *ListsIdTweetsQueries queries) returns Get2ListsIdTweetsResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}/tweets`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/openapi\.json(map headers = {}) returns record {}|error { - string resourcePath = string `/2/openapi.json`; + resource isolated function get openapi\.json(map headers = {}) returns record {}|error { + string resourcePath = string `/openapi.json`; return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces(map headers = {}, *FindSpacesByIdsQueries queries) returns Get2SpacesResponse|error { - string resourcePath = string `/2/spaces`; + # Space lookup up Space IDs + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get spaces(map headers = {}, *FindSpacesByIdsQueries queries) returns Get2SpacesResponse|error { + string resourcePath = string `/spaces`; map queryParamEncoding = {"ids": {style: FORM, explode: true}, "space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces/'by/creator_ids(map headers = {}, *FindSpacesByCreatorIdsQueries queries) returns Get2SpacesByCreatorIdsResponse|error { - string resourcePath = string `/2/spaces/by/creator_ids`; + resource isolated function get spaces/'by/creator_ids(map headers = {}, *FindSpacesByCreatorIdsQueries queries) returns Get2SpacesByCreatorIdsResponse|error { + string resourcePath = string `/spaces/by/creator_ids`; map queryParamEncoding = {"user_ids": {style: FORM, explode: true}, "space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces/[string id](map headers = {}, *FindSpaceByIdQueries queries) returns Get2SpacesIdResponse|error { - string resourcePath = string `/2/spaces/${getEncodedUri(id)}`; + # Space lookup by Space ID + # + # + id - The ID of the Space to be retrieved. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get spaces/[string id](map headers = {}, *FindSpaceByIdQueries queries) returns Get2SpacesIdResponse|error { + string resourcePath = string `/spaces/${getEncodedUri(id)}`; map queryParamEncoding = {"space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces/[string id]/buyers(map headers = {}, *SpaceBuyersQueries queries) returns Get2SpacesIdBuyersResponse|error { - string resourcePath = string `/2/spaces/${getEncodedUri(id)}/buyers`; + # Retrieve the list of Users who purchased a ticket to the given space + # + # + id - The ID of the Space to be retrieved. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get spaces/[string id]/buyers(map headers = {}, *SpaceBuyersQueries queries) returns Get2SpacesIdBuyersResponse|error { + string resourcePath = string `/spaces/${getEncodedUri(id)}/buyers`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces/[string id]/tweets(map headers = {}, *SpaceTweetsQueries queries) returns Get2SpacesIdTweetsResponse|error { - string resourcePath = string `/2/spaces/${getEncodedUri(id)}/tweets`; + # Retrieve Posts from a Space. + # + # + id - The ID of the Space to be retrieved. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get spaces/[string id]/tweets(map headers = {}, *SpaceTweetsQueries queries) returns Get2SpacesIdTweetsResponse|error { + string resourcePath = string `/spaces/${getEncodedUri(id)}/tweets`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/spaces/search(map headers = {}, *SearchSpacesQueries queries) returns Get2SpacesSearchResponse|error { - string resourcePath = string `/2/spaces/search`; + # Search for Spaces + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get spaces/search(map headers = {}, *SearchSpacesQueries queries) returns Get2SpacesSearchResponse|error { + string resourcePath = string `/spaces/search`; map queryParamEncoding = {"space.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "topic.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/trends/'by/woeid/[int:Signed32 woeid](map headers = {}, *GetTrendsQueries queries) returns Get2TrendsByWoeidWoeidResponse|error { - string resourcePath = string `/2/trends/by/woeid/${getEncodedUri(woeid)}`; + resource isolated function get trends/'by/woeid/[int:Signed32 woeid](map headers = {}, *GetTrendsQueries queries) returns Get2TrendsByWoeidWoeidResponse|error { + string resourcePath = string `/trends/by/woeid/${getEncodedUri(woeid)}`; map queryParamEncoding = {"trend.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets(map headers = {}, *FindTweetsByIdQueries queries) returns Get2TweetsResponse|error { - string resourcePath = string `/2/tweets`; + # Post lookup by Post IDs + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets(map headers = {}, *FindTweetsByIdQueries queries) returns Get2TweetsResponse|error { + string resourcePath = string `/tweets`; map queryParamEncoding = {"ids": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/[TweetId id](map headers = {}, *FindTweetByIdQueries queries) returns Get2TweetsIdResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}`; + # Post lookup by Post ID + # + # + id - A single Post ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/[TweetId id](map headers = {}, *FindTweetByIdQueries queries) returns Get2TweetsIdResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/[TweetId id]/liking_users(map headers = {}, *TweetsIdLikingUsersQueries queries) returns Get2TweetsIdLikingUsersResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}/liking_users`; + # Returns User objects that have liked the provided Post ID + # + # + id - A single Post ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/[TweetId id]/liking_users(map headers = {}, *TweetsIdLikingUsersQueries queries) returns Get2TweetsIdLikingUsersResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}/liking_users`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/[TweetId id]/quote_tweets(map headers = {}, *FindTweetsThatQuoteATweetQueries queries) returns Get2TweetsIdQuoteTweetsResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}/quote_tweets`; + # Retrieve Posts that quote a Post. + # + # + id - A single Post ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/[TweetId id]/quote_tweets(map headers = {}, *FindTweetsThatQuoteATweetQueries queries) returns Get2TweetsIdQuoteTweetsResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}/quote_tweets`; map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/[TweetId id]/retweeted_by(map headers = {}, *TweetsIdRetweetingUsersQueries queries) returns Get2TweetsIdRetweetedByResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}/retweeted_by`; + # Returns User objects that have retweeted the provided Post ID + # + # + id - A single Post ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/[TweetId id]/retweeted_by(map headers = {}, *TweetsIdRetweetingUsersQueries queries) returns Get2TweetsIdRetweetedByResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}/retweeted_by`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/[TweetId id]/retweets(map headers = {}, *FindTweetsThatRetweetATweetQueries queries) returns Get2TweetsIdRetweetsResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(id)}/retweets`; + # Retrieve Posts that repost a Post. + # + # + id - A single Post ID. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/[TweetId id]/retweets(map headers = {}, *FindTweetsThatRetweetATweetQueries queries) returns Get2TweetsIdRetweetsResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(id)}/retweets`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/compliance/'stream(map headers = {}, *GetTweetsComplianceStreamQueries queries) returns TweetComplianceStreamResponse|error { - string resourcePath = string `/2/tweets/compliance/stream`; + resource isolated function get tweets/compliance/'stream(map headers = {}, *GetTweetsComplianceStreamQueries queries) returns TweetComplianceStreamResponse|error { + string resourcePath = string `/tweets/compliance/stream`; resourcePath = resourcePath + check getPathForQueryParam(queries); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/counts/all(map headers = {}, *TweetCountsFullArchiveSearchQueries queries) returns Get2TweetsCountsAllResponse|error { - string resourcePath = string `/2/tweets/counts/all`; + # Full archive search counts + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/counts/all(map headers = {}, *TweetCountsFullArchiveSearchQueries queries) returns Get2TweetsCountsAllResponse|error { + string resourcePath = string `/tweets/counts/all`; map queryParamEncoding = {"search_count.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/counts/recent(map headers = {}, *TweetCountsRecentSearchQueries queries) returns Get2TweetsCountsRecentResponse|error { - string resourcePath = string `/2/tweets/counts/recent`; + # Recent search counts + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/counts/recent(map headers = {}, *TweetCountsRecentSearchQueries queries) returns Get2TweetsCountsRecentResponse|error { + string resourcePath = string `/tweets/counts/recent`; map queryParamEncoding = {"search_count.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/firehose/'stream(map headers = {}, *GetTweetsFirehoseStreamQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/firehose/stream`; + resource isolated function get tweets/firehose/'stream(map headers = {}, *GetTweetsFirehoseStreamQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/firehose/stream`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/firehose/'stream/lang/en(map headers = {}, *GetTweetsFirehoseStreamLangEnQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/firehose/stream/lang/en`; + resource isolated function get tweets/firehose/'stream/lang/en(map headers = {}, *GetTweetsFirehoseStreamLangEnQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/firehose/stream/lang/en`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/firehose/'stream/lang/ja(map headers = {}, *GetTweetsFirehoseStreamLangJaQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/firehose/stream/lang/ja`; + resource isolated function get tweets/firehose/'stream/lang/ja(map headers = {}, *GetTweetsFirehoseStreamLangJaQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/firehose/stream/lang/ja`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/firehose/'stream/lang/ko(map headers = {}, *GetTweetsFirehoseStreamLangKoQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/firehose/stream/lang/ko`; + resource isolated function get tweets/firehose/'stream/lang/ko(map headers = {}, *GetTweetsFirehoseStreamLangKoQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/firehose/stream/lang/ko`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/firehose/'stream/lang/pt(map headers = {}, *GetTweetsFirehoseStreamLangPtQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/firehose/stream/lang/pt`; + resource isolated function get tweets/firehose/'stream/lang/pt(map headers = {}, *GetTweetsFirehoseStreamLangPtQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/firehose/stream/lang/pt`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/label/'stream(map headers = {}, *GetTweetsLabelStreamQueries queries) returns TweetLabelStreamResponse|error { - string resourcePath = string `/2/tweets/label/stream`; + resource isolated function get tweets/label/'stream(map headers = {}, *GetTweetsLabelStreamQueries queries) returns TweetLabelStreamResponse|error { + string resourcePath = string `/tweets/label/stream`; resourcePath = resourcePath + check getPathForQueryParam(queries); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/sample/'stream(map headers = {}, *SampleStreamQueries queries) returns StreamingTweetResponse|error { - string resourcePath = string `/2/tweets/sample/stream`; + resource isolated function get tweets/sample/'stream(map headers = {}, *SampleStreamQueries queries) returns StreamingTweetResponse|error { + string resourcePath = string `/tweets/sample/stream`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/sample10/'stream(map headers = {}, *GetTweetsSample10StreamQueries queries) returns Get2TweetsSample10StreamResponse|error { - string resourcePath = string `/2/tweets/sample10/stream`; + resource isolated function get tweets/sample10/'stream(map headers = {}, *GetTweetsSample10StreamQueries queries) returns Get2TweetsSample10StreamResponse|error { + string resourcePath = string `/tweets/sample10/stream`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/search/'stream(map headers = {}, *SearchStreamQueries queries) returns FilteredStreamingTweetResponse|error { - string resourcePath = string `/2/tweets/search/stream`; + resource isolated function get tweets/search/'stream(map headers = {}, *SearchStreamQueries queries) returns FilteredStreamingTweetResponse|error { + string resourcePath = string `/tweets/search/stream`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/search/'stream/rules(map headers = {}, *GetRulesQueries queries) returns RulesLookupResponse|error { - string resourcePath = string `/2/tweets/search/stream/rules`; + resource isolated function get tweets/search/'stream/rules(map headers = {}, *GetRulesQueries queries) returns RulesLookupResponse|error { + string resourcePath = string `/tweets/search/stream/rules`; map queryParamEncoding = {"ids": {style: FORM, explode: true}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/search/'stream/rules/counts(map headers = {}, *GetRuleCountQueries queries) returns Get2TweetsSearchStreamRulesCountsResponse|error { - string resourcePath = string `/2/tweets/search/stream/rules/counts`; + resource isolated function get tweets/search/'stream/rules/counts(map headers = {}, *GetRuleCountQueries queries) returns Get2TweetsSearchStreamRulesCountsResponse|error { + string resourcePath = string `/tweets/search/stream/rules/counts`; map queryParamEncoding = {"rules_count.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/search/all(map headers = {}, *TweetsFullarchiveSearchQueries queries) returns Get2TweetsSearchAllResponse|error { - string resourcePath = string `/2/tweets/search/all`; + # Full-archive search + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/search/all(map headers = {}, *TweetsFullarchiveSearchQueries queries) returns Get2TweetsSearchAllResponse|error { + string resourcePath = string `/tweets/search/all`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/tweets/search/recent(map headers = {}, *TweetsRecentSearchQueries queries) returns Get2TweetsSearchRecentResponse|error { - string resourcePath = string `/2/tweets/search/recent`; + # Recent search + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get tweets/search/recent(map headers = {}, *TweetsRecentSearchQueries queries) returns Get2TweetsSearchRecentResponse|error { + string resourcePath = string `/tweets/search/recent`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/usage/tweets(map headers = {}, *GetUsageTweetsQueries queries) returns Get2UsageTweetsResponse|error { - string resourcePath = string `/2/usage/tweets`; + # Post Usage + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get usage/tweets(map headers = {}, *GetUsageTweetsQueries queries) returns Get2UsageTweetsResponse|error { + string resourcePath = string `/usage/tweets`; map queryParamEncoding = {"usage.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users(map headers = {}, *FindUsersByIdQueries queries) returns Get2UsersResponse|error { - string resourcePath = string `/2/users`; + # User lookup by IDs + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users(map headers = {}, *FindUsersByIdQueries queries) returns Get2UsersResponse|error { + string resourcePath = string `/users`; map queryParamEncoding = {"ids": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/'by(map headers = {}, *FindUsersByUsernameQueries queries) returns Get2UsersByResponse|error { - string resourcePath = string `/2/users/by`; + resource isolated function get users/'by(map headers = {}, *FindUsersByUsernameQueries queries) returns Get2UsersByResponse|error { + string resourcePath = string `/users/by`; map queryParamEncoding = {"usernames": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/'by/username/[string username](map headers = {}, *FindUserByUsernameQueries queries) returns Get2UsersByUsernameUsernameResponse|error { - string resourcePath = string `/2/users/by/username/${getEncodedUri(username)}`; + resource isolated function get users/'by/username/[string username](map headers = {}, *FindUserByUsernameQueries queries) returns Get2UsersByUsernameUsernameResponse|error { + string resourcePath = string `/users/by/username/${getEncodedUri(username)}`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/blocking(map headers = {}, *UsersIdBlockingQueries queries) returns Get2UsersIdBlockingResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/blocking`; + # Returns User objects that are blocked by provided User ID + # + # + id - The ID of the authenticated source User for whom to return results. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserIdMatchesAuthenticatedUser id]/blocking(map headers = {}, *UsersIdBlockingQueries queries) returns Get2UsersIdBlockingResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/blocking`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks(map headers = {}, *GetUsersIdBookmarksQueries queries) returns Get2UsersIdBookmarksResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks`; + # Bookmarks by User + # + # + id - The ID of the authenticated source User for whom to return results. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserIdMatchesAuthenticatedUser id]/bookmarks(map headers = {}, *GetUsersIdBookmarksQueries queries) returns Get2UsersIdBookmarksResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/bookmarks`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/muting(map headers = {}, *UsersIdMutingQueries queries) returns Get2UsersIdMutingResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/muting`; + # Returns User objects that are muted by the provided User ID + # + # + id - The ID of the authenticated source User for whom to return results. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserIdMatchesAuthenticatedUser id]/muting(map headers = {}, *UsersIdMutingQueries queries) returns Get2UsersIdMutingResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/muting`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(map headers = {}, *ListUserPinnedListsQueries queries) returns Get2UsersIdPinnedListsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists`; + # Get a User's Pinned Lists + # + # + id - The ID of the authenticated source User for whom to return results. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(map headers = {}, *ListUserPinnedListsQueries queries) returns Get2UsersIdPinnedListsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/pinned_lists`; map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserIdMatchesAuthenticatedUser id]/timelines/reverse_chronological(map headers = {}, *UsersIdTimelineQueries queries) returns Get2UsersIdTimelinesReverseChronologicalResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/timelines/reverse_chronological`; + # User home timeline by User ID + # + # + id - The ID of the authenticated source User to list Reverse Chronological Timeline Posts of. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserIdMatchesAuthenticatedUser id]/timelines/reverse_chronological(map headers = {}, *UsersIdTimelineQueries queries) returns Get2UsersIdTimelinesReverseChronologicalResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/timelines/reverse_chronological`; map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id](map headers = {}, *FindUserByIdQueries queries) returns Get2UsersIdResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}`; + # User lookup by ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id](map headers = {}, *FindUserByIdQueries queries) returns Get2UsersIdResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/followed_lists(map headers = {}, *UserFollowedListsQueries queries) returns Get2UsersIdFollowedListsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists`; + # Get User's Followed Lists + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/followed_lists(map headers = {}, *UserFollowedListsQueries queries) returns Get2UsersIdFollowedListsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/followed_lists`; map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/followers(map headers = {}, *UsersIdFollowersQueries queries) returns Get2UsersIdFollowersResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/followers`; + # Followers by User ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/followers(map headers = {}, *UsersIdFollowersQueries queries) returns Get2UsersIdFollowersResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/followers`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/following(map headers = {}, *UsersIdFollowingQueries queries) returns Get2UsersIdFollowingResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/following`; + # Following by User ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/following(map headers = {}, *UsersIdFollowingQueries queries) returns Get2UsersIdFollowingResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/following`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/liked_tweets(map headers = {}, *UsersIdLikedTweetsQueries queries) returns Get2UsersIdLikedTweetsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/liked_tweets`; + # Returns Post objects liked by the provided User ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/liked_tweets(map headers = {}, *UsersIdLikedTweetsQueries queries) returns Get2UsersIdLikedTweetsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/liked_tweets`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/list_memberships(map headers = {}, *GetUserListMembershipsQueries queries) returns Get2UsersIdListMembershipsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/list_memberships`; + # Get a User's List Memberships + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/list_memberships(map headers = {}, *GetUserListMembershipsQueries queries) returns Get2UsersIdListMembershipsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/list_memberships`; map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/mentions(map headers = {}, *UsersIdMentionsQueries queries) returns Get2UsersIdMentionsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/mentions`; + # User mention timeline by User ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/mentions(map headers = {}, *UsersIdMentionsQueries queries) returns Get2UsersIdMentionsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/mentions`; map queryParamEncoding = {"tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/owned_lists(map headers = {}, *ListUserOwnedListsQueries queries) returns Get2UsersIdOwnedListsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/owned_lists`; + # Get a User's Owned Lists. + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/owned_lists(map headers = {}, *ListUserOwnedListsQueries queries) returns Get2UsersIdOwnedListsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/owned_lists`; map queryParamEncoding = {"list.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/[UserId id]/tweets(map headers = {}, *UsersIdTweetsQueries queries) returns Get2UsersIdTweetsResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/tweets`; + # User Posts timeline by User ID + # + # + id - The ID of the User to lookup. + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/[UserId id]/tweets(map headers = {}, *UsersIdTweetsQueries queries) returns Get2UsersIdTweetsResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/tweets`; map queryParamEncoding = {"exclude": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "media.fields": {style: FORM, explode: false}, "poll.fields": {style: FORM, explode: false}, "user.fields": {style: FORM, explode: false}, "place.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/compliance/'stream(map headers = {}, *GetUsersComplianceStreamQueries queries) returns UserComplianceStreamResponse|error { - string resourcePath = string `/2/users/compliance/stream`; + resource isolated function get users/compliance/'stream(map headers = {}, *GetUsersComplianceStreamQueries queries) returns UserComplianceStreamResponse|error { + string resourcePath = string `/users/compliance/stream`; resourcePath = resourcePath + check getPathForQueryParam(queries); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/me(map headers = {}, *FindMyUserQueries queries) returns Get2UsersMeResponse|error { - string resourcePath = string `/2/users/me`; + # User lookup me + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/me(map headers = {}, *FindMyUserQueries queries) returns Get2UsersMeResponse|error { + string resourcePath = string `/users/me`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function get '2/users/search(map headers = {}, *SearchUserByQueryQueries queries) returns Get2UsersSearchResponse|error { - string resourcePath = string `/2/users/search`; + # User search + # + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - The request has succeeded. + resource isolated function get users/search(map headers = {}, *SearchUserByQueryQueries queries) returns Get2UsersSearchResponse|error { + string resourcePath = string `/users/search`; map queryParamEncoding = {"user.fields": {style: FORM, explode: false}, "expansions": {style: FORM, explode: false}, "tweet.fields": {style: FORM, explode: false}}; resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); return self.clientEp->get(resourcePath, headers); } - resource isolated function post '2/compliance/jobs(CreateComplianceJobRequest payload, map headers = {}) returns CreateComplianceJobResponse|error { - string resourcePath = string `/2/compliance/jobs`; + # Create compliance job + # + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post compliance/jobs(CreateComplianceJobRequest payload, map headers = {}) returns CreateComplianceJobResponse|error { + string resourcePath = string `/compliance/jobs`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/dm_conversations(CreateDmConversationRequest payload, map headers = {}) returns CreateDmEventResponse|error { - string resourcePath = string `/2/dm_conversations`; + # Create a new DM Conversation + # + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post dm_conversations(CreateDmConversationRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/dm_conversations`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/dm_conversations/[string dm_conversation_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { - string resourcePath = string `/2/dm_conversations/${getEncodedUri(dm_conversation_id)}/messages`; + # Send a new message to a DM Conversation + # + # + dm_conversation_id - The DM Conversation ID. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post dm_conversations/[string dm_conversation_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/dm_conversations/${getEncodedUri(dm_conversation_id)}/messages`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/dm_conversations/with/[UserId participant_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { - string resourcePath = string `/2/dm_conversations/with/${getEncodedUri(participant_id)}/messages`; + # Send a new message to a user + # + # + participant_id - The ID of the recipient user that will receive the DM. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post dm_conversations/with/[UserId participant_id]/messages(CreateMessageRequest payload, map headers = {}) returns CreateDmEventResponse|error { + string resourcePath = string `/dm_conversations/with/${getEncodedUri(participant_id)}/messages`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/lists(ListCreateRequest payload, map headers = {}) returns ListCreateResponse|error { - string resourcePath = string `/2/lists`; + # Create List + # + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post lists(ListCreateRequest payload, map headers = {}) returns ListCreateResponse|error { + string resourcePath = string `/lists`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/lists/[ListId id]/members(ListAddUserRequest payload, map headers = {}) returns ListMutateResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}/members`; + # Add a List member + # + # + id - The ID of the List for which to add a member. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post lists/[ListId id]/members(ListAddUserRequest payload, map headers = {}) returns ListMutateResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}/members`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/tweets(TweetCreateRequest payload, map headers = {}) returns TweetCreateResponse|error { - string resourcePath = string `/2/tweets`; + # Creation of a Post + # + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post tweets(TweetCreateRequest payload, map headers = {}) returns TweetCreateResponse|error { + string resourcePath = string `/tweets`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/tweets/search/'stream/rules(AddOrDeleteRulesRequest payload, map headers = {}, *AddOrDeleteRulesQueries queries) returns AddOrDeleteRulesResponse|error { - string resourcePath = string `/2/tweets/search/stream/rules`; + resource isolated function post tweets/search/'stream/rules(AddOrDeleteRulesRequest payload, map headers = {}, *AddOrDeleteRulesQueries queries) returns AddOrDeleteRulesResponse|error { + string resourcePath = string `/tweets/search/stream/rules`; resourcePath = resourcePath + check getPathForQueryParam(queries); http:Request request = new; json jsonBody = payload.toJson(); @@ -617,72 +956,117 @@ public isolated client class Client { return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/bookmarks(BookmarkAddRequest payload, map headers = {}) returns BookmarkMutationResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/bookmarks`; + # Add Post to Bookmarks + # + # + id - The ID of the authenticated source User for whom to add bookmarks. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/bookmarks(BookmarkAddRequest payload, map headers = {}) returns BookmarkMutationResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/bookmarks`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/followed_lists(ListFollowedRequest payload, map headers = {}) returns ListFollowedResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/followed_lists`; + # Follow a List + # + # + id - The ID of the authenticated source User that will follow the List. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/followed_lists(ListFollowedRequest payload, map headers = {}) returns ListFollowedResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/followed_lists`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/following(UsersFollowingCreateRequest payload, map headers = {}) returns UsersFollowingCreateResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/following`; + # Follow User + # + # + id - The ID of the authenticated source User that is requesting to follow the target User. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/following(UsersFollowingCreateRequest payload, map headers = {}) returns UsersFollowingCreateResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/following`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/likes(UsersLikesCreateRequest payload, map headers = {}) returns UsersLikesCreateResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/likes`; + # Causes the User (in the path) to like the specified Post + # + # + id - The ID of the authenticated source User that is requesting to like the Post. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/likes(UsersLikesCreateRequest payload, map headers = {}) returns UsersLikesCreateResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/likes`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/muting(MuteUserRequest payload, map headers = {}) returns MuteUserMutationResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/muting`; + # Mute User by User ID. + # + # + id - The ID of the authenticated source User that is requesting to mute the target User. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/muting(MuteUserRequest payload, map headers = {}) returns MuteUserMutationResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/muting`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(ListPinnedRequest payload, map headers = {}) returns ListPinnedResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/pinned_lists`; + # Pin a List + # + # + id - The ID of the authenticated source User that will pin the List. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/pinned_lists(ListPinnedRequest payload, map headers = {}) returns ListPinnedResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/pinned_lists`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function post '2/users/[UserIdMatchesAuthenticatedUser id]/retweets(UsersRetweetsCreateRequest payload, map headers = {}) returns UsersRetweetsCreateResponse|error { - string resourcePath = string `/2/users/${getEncodedUri(id)}/retweets`; + # Causes the User (in the path) to repost the specified Post. + # + # + id - The ID of the authenticated source User that is requesting to repost the Post. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function post users/[UserIdMatchesAuthenticatedUser id]/retweets(UsersRetweetsCreateRequest payload, map headers = {}) returns UsersRetweetsCreateResponse|error { + string resourcePath = string `/users/${getEncodedUri(id)}/retweets`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->post(resourcePath, request, headers); } - resource isolated function put '2/lists/[ListId id](ListUpdateRequest payload, map headers = {}) returns ListUpdateResponse|error { - string resourcePath = string `/2/lists/${getEncodedUri(id)}`; + # Update List. + # + # + id - The ID of the List to modify. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function put lists/[ListId id](ListUpdateRequest payload, map headers = {}) returns ListUpdateResponse|error { + string resourcePath = string `/lists/${getEncodedUri(id)}`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); return self.clientEp->put(resourcePath, request, headers); } - resource isolated function put '2/tweets/[TweetId tweet_id]/hidden(TweetHideRequest payload, map headers = {}) returns TweetHideResponse|error { - string resourcePath = string `/2/tweets/${getEncodedUri(tweet_id)}/hidden`; + # Hide replies + # + # + tweet_id - The ID of the reply that you want to hide or unhide. + # + headers - Headers to be sent with the request + # + return - The request has succeeded. + resource isolated function put tweets/[TweetId tweet_id]/hidden(TweetHideRequest payload, map headers = {}) returns TweetHideResponse|error { + string resourcePath = string `/tweets/${getEncodedUri(tweet_id)}/hidden`; http:Request request = new; json jsonBody = payload.toJson(); request.setPayload(jsonBody, "application/json"); diff --git a/ballerina/types.bal b/ballerina/types.bal index d565777..1c8a05b 100644 --- a/ballerina/types.bal +++ b/ballerina/types.bal @@ -139,14 +139,14 @@ public type TweetUnviewableSchema record { TweetUnviewable public_tweet_unviewable; }; -# HTTP Status Code. -@constraint:Int {minValue: 100, maxValue: 599} -public type HttpStatusCode int; - public type ListUpdateResponse_data record { boolean updated?; }; +# HTTP Status Code. +@constraint:Int {minValue: 100, maxValue: 599} +public type HttpStatusCode int; + # Specifies the type of attachments (if any) present in this Tweet. public type Tweet_attachments record { # A list of Media Keys for each one of the media attachments (if media are attached). @@ -160,6 +160,9 @@ public type Tweet_attachments record { PollId[] poll_ids?; }; +# Tweet label data. +public type TweetLabelData TweetNoticeSchema|TweetUnviewableSchema; + # Represents the Queries record for the operation: usersIdLikedTweets public type UsersIdLikedTweetsQueries record { # A comma separated list of Poll fields to display. @@ -182,9 +185,6 @@ public type UsersIdLikedTweetsQueries record { ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; }; -# Tweet label data. -public type TweetLabelData TweetNoticeSchema|TweetUnviewableSchema; - public type UserScrubGeoObjectSchema record { # Event time. string event_at; @@ -485,17 +485,17 @@ public type ListBatchComplianceJobsQueries record { "created"|"in_progress"|"failed"|"complete" status?; }; -public type Get2UsersByUsernameUsernameResponse record { - User data?; +public type ListCreateResponse record { + ListCreateResponse_data data?; @constraint:Array {minLength: 1} Problem[] errors?; - Expansions includes?; }; -public type ListCreateResponse record { - ListCreateResponse_data data?; +public type Get2UsersByUsernameUsernameResponse record { + User data?; @constraint:Array {minLength: 1} Problem[] errors?; + Expansions includes?; }; public type CreateDmEventResponse record { @@ -738,21 +738,6 @@ public type Get2TweetsCountsAllResponse record { Get2TweetsCountsAllResponse_meta meta?; }; -# Nonpublic engagement metrics for the Tweet at the time of the request. -public type Tweet_non_public_metrics record { - # Number of times this Tweet has been viewed. - int:Signed32 impression_count?; -}; - -public type Tweet_referenced_tweets record { - TweetId id; - "retweeted"|"quoted"|"replied_to" 'type; -}; - -# User-provided name for a compliance job. -@constraint:String {maxLength: 64} -public type ComplianceJobName string; - # Represents the Queries record for the operation: listIdGet public type ListIdGetQueries record { # A comma separated list of User fields to display. @@ -764,8 +749,15 @@ public type ListIdGetQueries record { ("owner_id")[] expansions?; }; -public type TweetDropComplianceSchema record { - TweetComplianceSchema drop; +# Nonpublic engagement metrics for the Tweet at the time of the request. +public type Tweet_non_public_metrics record { + # Number of times this Tweet has been viewed. + int:Signed32 impression_count?; +}; + +public type Tweet_referenced_tweets record { + TweetId id; + "retweeted"|"quoted"|"replied_to" 'type; }; # The sum of results returned in this response. @@ -780,6 +772,14 @@ public type Get2DmConversationsWithParticipantIdDmEventsResponse record { Get2DmConversationsIdDmEventsResponse_meta meta?; }; +# User-provided name for a compliance job. +@constraint:String {maxLength: 64} +public type ComplianceJobName string; + +public type TweetDropComplianceSchema record { + TweetComplianceSchema drop; +}; + public type ListUpdateRequest record { @constraint:String {maxLength: 100} string description?; @@ -905,14 +905,14 @@ public type DeleteDmResponse record { Problem[] errors?; }; -# Participants for the DM Conversation. -@constraint:Array {maxLength: 49, minLength: 2} -public type DmParticipants UserId[]; - # The ID of the client application @constraint:String {maxLength: 19, minLength: 1} public type ClientAppId string; +# Participants for the DM Conversation. +@constraint:Array {maxLength: 49, minLength: 2} +public type DmParticipants UserId[]; + # The unique identifier of this Like. @constraint:String {pattern: re `^[A-Za-z0-9_]{1,40}$`} public type LikeId string; @@ -947,15 +947,15 @@ public type TweetWithheldComplianceSchema record { # URL from which the user will retrieve their compliance results. public type DownloadUrl string; -@constraint:String {maxLength: 25, minLength: 1} -public type TweetCreateRequest_pollOptionsItemsString string; - # A user-provided stream filtering rule. public type RuleNoId record { RuleTag tag?; RuleValue value; }; +@constraint:String {maxLength: 25, minLength: 1} +public type TweetCreateRequest_pollOptionsItemsString string; + public type UserProfileModificationObjectSchema record { # Event time. string event_at; @@ -1030,6 +1030,14 @@ public type UnlikeComplianceSchema_favorite record { UserId user_id; }; +# The end time of the bucket. +public type End string; + +public type FilteredStreamingTweetResponse_matching_rules record { + RuleId id; + RuleTag tag?; +}; + # A count of user-provided stream filtering rules at the application and project levels. public type RulesCount record { AllProjectClientApps all_project_client_apps?; @@ -1051,14 +1059,6 @@ public type Get2TweetsIdRetweetsResponse record { Get2DmConversationsIdDmEventsResponse_meta meta?; }; -# The end time of the bucket. -public type End string; - -public type FilteredStreamingTweetResponse_matching_rules record { - RuleId id; - RuleTag tag?; -}; - public type MuteUserRequest record { UserId target_user_id; }; @@ -1155,6 +1155,11 @@ public type TweetHideRequest record { public type AddOrDeleteRulesRequest AddRulesRequest|DeleteRulesRequest; +public type RulesLookupResponse record { + Rule[] data?; + RulesResponseMetadata meta; +}; + # Represents the Queries record for the operation: spaceBuyers public type SpaceBuyersQueries record { # A comma separated list of User fields to display. @@ -1171,28 +1176,23 @@ public type SpaceBuyersQueries record { ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; }; -public type RulesLookupResponse record { - Rule[] data?; - RulesResponseMetadata meta; -}; - public type ListUnpinResponse record { ListPinnedResponse_data data?; @constraint:Array {minLength: 1} Problem[] errors?; }; -public type CreateDmEventResponse_data record { - DmConversationId dm_conversation_id; - DmEventId dm_event_id; -}; - public type UsersLikesCreateResponse record { UsersLikesCreateResponse_data data?; @constraint:Array {minLength: 1} Problem[] errors?; }; +public type CreateDmEventResponse_data record { + DmConversationId dm_conversation_id; + DmEventId dm_event_id; +}; + public type Get2SpacesResponse record { @constraint:Array {minLength: 1} Space[] data?; @@ -1221,6 +1221,15 @@ public type OAuth2RefreshTokenGrantConfig record {| string refreshUrl = "https://api.twitter.com/2/oauth2/token"; |}; +# Describes a choice in a Poll object. +public type PollOption record { + PollOptionLabel label; + # Position of this choice in the poll. + int position; + # Number of users who voted for this choice. + int votes; +}; + # Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is exclusive. public type EntityIndicesInclusiveExclusive record { # Index (zero-based) at which position this entity ends. The index is exclusive. @@ -1231,15 +1240,6 @@ public type EntityIndicesInclusiveExclusive record { int 'start; }; -# Describes a choice in a Poll object. -public type PollOption record { - PollOptionLabel label; - # Position of this choice in the poll. - int position; - # Number of users who voted for this choice. - int votes; -}; - # Represents the Queries record for the operation: getDmConversationsIdDmEvents public type GetDmConversationsIdDmEventsQueries record { # A comma separated list of DmEvent fields to display. @@ -1292,15 +1292,6 @@ public type ListFollowedResponse_data record { @constraint:String {pattern: re `^[A-Za-z0-9_]{1,15}$`} public type UserName string; -# Represents the Queries record for the operation: getUsageTweets -public type GetUsageTweetsQueries record { - # A comma separated list of Usage fields to display. - ("cap_reset_day"|"daily_client_app_usage"|"daily_project_usage"|"project_cap"|"project_id"|"project_usage")[] usage\.fields?; - # The number of days for which you need usage for. - @constraint:Int {minValue: 1, maxValue: 90} - int:Signed32 days = 7; -}; - # Represents the Queries record for the operation: getTweetsFirehoseStreamLangKo public type GetTweetsFirehoseStreamLangKoQueries record { # A comma separated list of Poll fields to display. @@ -1328,6 +1319,15 @@ public type GetTweetsFirehoseStreamLangKoQueries record { ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; }; +# Represents the Queries record for the operation: getUsageTweets +public type GetUsageTweetsQueries record { + # A comma separated list of Usage fields to display. + ("cap_reset_day"|"daily_client_app_usage"|"daily_project_usage"|"project_cap"|"project_id"|"project_usage")[] usage\.fields?; + # The number of days for which you need usage for. + @constraint:Int {minValue: 1, maxValue: 90} + int:Signed32 days = 7; +}; + @constraint:String {pattern: re `^[a-zA-Z0-9]{1,13}$`} public type FindSpacesByIdsQueriesIdsItemsString string; @@ -1355,10 +1355,6 @@ public type Get2ComplianceJobsResponse record { Get2ComplianceJobsResponse_meta meta?; }; -public type UsersFollowingCreateRequest record { - UserId target_user_id; -}; - # Usage per client app public type ClientAppUsage record { # The unique identifier for this project @@ -1370,6 +1366,10 @@ public type ClientAppUsage record { int:Signed32 usage_result_count?; }; +public type UsersFollowingCreateRequest record { + UserId target_user_id; +}; + # Tweet information of the Tweet being replied to. public type TweetCreateRequest_reply record {| # A list of User Ids to be excluded from the reply Tweet. @@ -1377,13 +1377,6 @@ public type TweetCreateRequest_reply record {| TweetId in_reply_to_tweet_id; |}; -public type Get2TrendsByWoeidWoeidResponse record { - @constraint:Array {minLength: 1} - Trend[] data?; - @constraint:Array {minLength: 1} - Problem[] errors?; -}; - # Represents the Queries record for the operation: findSpaceById public type FindSpaceByIdQueries record { # A comma separated list of Space fields to display. @@ -1397,6 +1390,13 @@ public type FindSpaceByIdQueries record { ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; }; +public type Get2TrendsByWoeidWoeidResponse record { + @constraint:Array {minLength: 1} + Trend[] data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + public type CreateAttachmentsMessageRequest record { DmAttachments attachments; # Text of the message. @@ -1438,16 +1438,16 @@ public type Get2TweetsIdResponse record { Expansions includes?; }; +public type TweetHideResponse_data record { + boolean hidden?; +}; + # Represents the Queries record for the operation: getTrends public type GetTrendsQueries record { # A comma separated list of Trend fields to display. ("trend_name"|"tweet_count")[] trend\.fields?; }; -public type TweetHideResponse_data record { - boolean hidden?; -}; - # Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country). public type TweetWithheld record { # Indicates if the content is being withheld for on the basis of copyright infringement. @@ -1459,10 +1459,6 @@ public type TweetWithheld record { "tweet"|"user" scope?; }; -public type UsersRetweetsDeleteResponse_data record { - boolean retweeted?; -}; - # IDs and values of all deleted user-specified stream filtering rules. public type DeleteRulesRequest_delete record { # IDs of all deleted user-specified stream filtering rules. @@ -1471,6 +1467,10 @@ public type DeleteRulesRequest_delete record { RuleValue[] values?; }; +public type UsersRetweetsDeleteResponse_data record { + boolean retweeted?; +}; + # A count of user-provided stream filtering rules at the client application level. public type AppRulesCount record { ClientAppId client_app_id?; @@ -1785,6 +1785,13 @@ public type Get2UsersIdTweetsResponse record { Get2UsersIdMentionsResponse_meta meta?; }; +public type Get2UsersMeResponse record { + User data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; +}; + # Represents the Queries record for the operation: usersIdMentions public type UsersIdMentionsQueries record { # A comma separated list of Poll fields to display. @@ -1824,13 +1831,6 @@ public type TweetEditComplianceObjectSchema record { DmEvent_referenced_tweets tweet; }; -public type Get2UsersMeResponse record { - User data?; - @constraint:Array {minLength: 1} - Problem[] errors?; - Expansions includes?; -}; - # Tweet compliance data. public type TweetComplianceData TweetDeleteComplianceSchema|TweetWithheldComplianceSchema|TweetDropComplianceSchema|TweetUndropComplianceSchema|TweetEditComplianceSchema; @@ -1851,6 +1851,8 @@ public type ListFollowedRequest record { ListId list_id; }; +public type RulesRequestSummary record {int:Signed32 created; int:Signed32 invalid; int:Signed32 not_created; int:Signed32 valid;}|record {int:Signed32 deleted; int:Signed32 not_deleted;}; + # Represents the Queries record for the operation: findTweetsThatRetweetATweet public type FindTweetsThatRetweetATweetQueries record { # A comma separated list of Poll fields to display. @@ -1873,8 +1875,6 @@ public type FindTweetsThatRetweetATweetQueries record { ("attachments.media_keys"|"attachments.media_source_tweet"|"attachments.poll_ids"|"author_id"|"edit_history_tweet_ids"|"entities.mentions.username"|"geo.place_id"|"in_reply_to_user_id"|"entities.note.mentions.username"|"referenced_tweets.id"|"referenced_tweets.id.author_id"|"author_screen_name")[] expansions?; }; -public type RulesRequestSummary record {int:Signed32 created; int:Signed32 invalid; int:Signed32 not_created; int:Signed32 valid;}|record {int:Signed32 deleted; int:Signed32 not_deleted;}; - # Represents the Queries record for the operation: findTweetsById public type FindTweetsByIdQueries record { # A comma separated list of Poll fields to display. @@ -1978,6 +1978,22 @@ public type Get2SpacesIdTweetsResponse record { Get2DmConversationsIdDmEventsResponse_meta meta?; }; +# Represents the Queries record for the operation: usersIdFollowers +public type UsersIdFollowersQueries record { + # A comma separated list of User fields to display. + ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; + # This parameter is used to get a specified 'page' of results. + PaginationToken32 pagination_token?; + # A comma separated list of Tweet fields to display. + ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; + # The maximum number of results. + @constraint:Int {minValue: 1, maxValue: 1000} + int:Signed32 max_results?; + # A comma separated list of fields to expand. + @constraint:Array {minLength: 1} + ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; +}; + # Represents the Queries record for the operation: likesSample10Stream public type LikesSample10StreamQueries record { # A comma separated list of Like fields to display. @@ -1999,21 +2015,8 @@ public type LikesSample10StreamQueries record { ("liked_tweet_id")[] expansions?; }; -# Represents the Queries record for the operation: usersIdFollowers -public type UsersIdFollowersQueries record { - # A comma separated list of User fields to display. - ("connection_status"|"created_at"|"description"|"entities"|"id"|"location"|"most_recent_tweet_id"|"name"|"pinned_tweet_id"|"profile_image_url"|"protected"|"public_metrics"|"receives_your_dm"|"subscription_type"|"url"|"username"|"verified"|"verified_type"|"withheld")[] user\.fields?; - # This parameter is used to get a specified 'page' of results. - PaginationToken32 pagination_token?; - # A comma separated list of Tweet fields to display. - ("attachments"|"author_id"|"card_uri"|"context_annotations"|"conversation_id"|"created_at"|"edit_controls"|"edit_history_tweet_ids"|"entities"|"geo"|"id"|"in_reply_to_user_id"|"lang"|"non_public_metrics"|"note_tweet"|"organic_metrics"|"possibly_sensitive"|"promoted_metrics"|"public_metrics"|"referenced_tweets"|"reply_settings"|"scopes"|"source"|"text"|"username"|"withheld")[] tweet\.fields?; - # The maximum number of results. - @constraint:Int {minValue: 1, maxValue: 1000} - int:Signed32 max_results?; - # A comma separated list of fields to expand. - @constraint:Array {minLength: 1} - ("most_recent_tweet_id"|"pinned_tweet_id")[] expansions?; -}; +# The count for the bucket. +public type TweetCount int; # Represents the Queries record for the operation: getTweetsComplianceStream public type GetTweetsComplianceStreamQueries record { @@ -2029,9 +2032,6 @@ public type GetTweetsComplianceStreamQueries record { string end_time?; }; -# The count for the bucket. -public type TweetCount int; - # Represents the Queries record for the operation: addOrDeleteRules public type AddOrDeleteRulesQueries record { # Dry Run can be used with both the add and delete action, with the expected result given, but without actually taking any action in the system (meaning the end state will always be as it was when the request was submitted). This is particularly useful to validate rule changes. @@ -2148,10 +2148,6 @@ public type TweetCreateRequest record {| TweetText text?; |}; -public type TweetDeleteComplianceSchema record { - TweetComplianceSchema delete; -}; - public type MuteUserMutationResponse_data record { boolean muting?; }; @@ -2165,6 +2161,10 @@ public type Get2SpacesSearchResponse record { Get2ComplianceJobsResponse_meta meta?; }; +public type TweetDeleteComplianceSchema record { + TweetComplianceSchema delete; +}; + # Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, subscribers, verified and following. public type ReplySettingsWithVerifiedUsers "everyone"|"mentionedUsers"|"following"|"other"|"subscribers"|"verified"; @@ -2385,6 +2385,17 @@ public type UserScrubGeoSchema record { UserScrubGeoObjectSchema scrub_geo; }; +# A Like event, with the liking user and the tweet being liked +public type Like record { + # Creation time of the Tweet. + string created_at?; + LikeId id?; + TweetId liked_tweet_id?; + UserId liking_user_id?; + # Timestamp in milliseconds of creation. + int:Signed32 timestamp_ms?; +}; + # Represents the Queries record for the operation: findSpacesByCreatorIds public type FindSpacesByCreatorIdsQueries record { # A comma separated list of Space fields to display. @@ -2415,17 +2426,6 @@ public type Get2DmEventsResponse record { Get2DmConversationsIdDmEventsResponse_meta meta?; }; -# A Like event, with the liking user and the tweet being liked -public type Like record { - # Creation time of the Tweet. - string created_at?; - LikeId id?; - TweetId liked_tweet_id?; - UserId liking_user_id?; - # Timestamp in milliseconds of creation. - int:Signed32 timestamp_ms?; -}; - public type TweetHideResponse record { TweetHideResponse_data data?; }; @@ -2457,6 +2457,10 @@ public type Get2UsageTweetsResponse record { @constraint:Int {minValue: 0} public type MediaWidth int; +public type BookmarkMutationResponse_data record { + boolean bookmarked?; +}; + # Media information being attached to created Tweet. This is mutually exclusive from Quote Tweet Id, Poll, and Card URI. public type TweetCreateRequest_media record {| # A list of Media Ids to be attached to a created Tweet. @@ -2467,29 +2471,25 @@ public type TweetCreateRequest_media record {| UserId[] tagged_user_ids?; |}; -public type BookmarkMutationResponse_data record { - boolean bookmarked?; -}; - -public type Get2SpacesByCreatorIdsResponse record { +public type Get2UsersIdOwnedListsResponse record { @constraint:Array {minLength: 1} - Space[] data?; + List[] data?; @constraint:Array {minLength: 1} Problem[] errors?; Expansions includes?; - Get2ComplianceJobsResponse_meta meta?; + Get2DmConversationsIdDmEventsResponse_meta meta?; }; # The oldest id in this response. public type OldestId string; -public type Get2UsersIdOwnedListsResponse record { +public type Get2SpacesByCreatorIdsResponse record { @constraint:Array {minLength: 1} - List[] data?; + Space[] data?; @constraint:Array {minLength: 1} Problem[] errors?; Expansions includes?; - Get2DmConversationsIdDmEventsResponse_meta meta?; + Get2ComplianceJobsResponse_meta meta?; }; public type CreateComplianceJobResponse record { @@ -2505,6 +2505,9 @@ public type SearchCount record { TweetCount tweet_count; }; +# The identifier for this place. +public type PlaceId string; + # Represents the data for the context annotation domain. public type ContextAnnotationDomainFields record { # Description of the context annotation domain. @@ -2516,9 +2519,6 @@ public type ContextAnnotationDomainFields record { string name?; }; -# The identifier for this place. -public type PlaceId string; - # The scopes for this tweet public type Tweet_scopes record { # Indicates if this Tweet is viewable by followers without the Tweet ID @@ -2647,12 +2647,6 @@ public type FindSpacesByIdsQueries record { ("creator_id"|"host_ids"|"invited_user_ids"|"speaker_ids"|"topic_ids")[] expansions?; }; -public type Get2ComplianceJobsIdResponse record { - ComplianceJob data?; - @constraint:Array {minLength: 1} - Problem[] errors?; -}; - # Represents the Queries record for the operation: tweetCountsRecentSearch public type TweetCountsRecentSearchQueries record { # YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute). @@ -2676,6 +2670,12 @@ public type TweetCountsRecentSearchQueries record { TweetId until_id?; }; +public type Get2ComplianceJobsIdResponse record { + ComplianceJob data?; + @constraint:Array {minLength: 1} + Problem[] errors?; +}; + # The location tagged on the Tweet, if the user provided one. public type Tweet_geo record { Point coordinates?; @@ -2768,6 +2768,16 @@ public type User record { # Tweet label stream events. public type TweetLabelStreamResponse record {TweetLabelData data;}|record {Problem[] errors;}; +# A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched. +public type FilteredStreamingTweetResponse record { + Tweet data?; + @constraint:Array {minLength: 1} + Problem[] errors?; + Expansions includes?; + # The list of rules which matched the Tweet + FilteredStreamingTweetResponse_matching_rules[] matching_rules?; +}; + # Represents the Queries record for the operation: tweetsFullarchiveSearch public type TweetsFullarchiveSearchQueries record { # A comma separated list of Poll fields to display. @@ -2805,16 +2815,6 @@ public type TweetsFullarchiveSearchQueries record { TweetId until_id?; }; -# A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched. -public type FilteredStreamingTweetResponse record { - Tweet data?; - @constraint:Array {minLength: 1} - Problem[] errors?; - Expansions includes?; - # The list of rules which matched the Tweet - FilteredStreamingTweetResponse_matching_rules[] matching_rules?; -}; - # The next token. @constraint:String {minLength: 1} public type NextToken string; @@ -2951,10 +2951,6 @@ public type Topic record { string name; }; -# Compliance Job ID. -@constraint:String {pattern: re `^[0-9]{1,19}$`} -public type JobId string; - public type TweetUnviewable record { # If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’. string application; @@ -2963,6 +2959,10 @@ public type TweetUnviewable record { TweetComplianceSchema_tweet tweet; }; +# Compliance Job ID. +@constraint:String {pattern: re `^[0-9]{1,19}$`} +public type JobId string; + public type UserProfileModificationComplianceSchema record { UserProfileModificationObjectSchema user_profile_modification; }; diff --git a/docs/spec/openapi.json b/docs/spec/openapi.json index 8ec6719..b807c8f 100644 --- a/docs/spec/openapi.json +++ b/docs/spec/openapi.json @@ -1,14672 +1,14659 @@ { - "openapi" : "3.0.0", - "info" : { - "description" : "Twitter API v2 available endpoints", - "version" : "2.100", - "title" : "Twitter API v2", - "termsOfService" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html", - "contact" : { - "name" : "Twitter Developers", - "url" : "https://developer.twitter.com/" - }, - "license" : { - "name" : "Twitter Developer Agreement and Policy", - "url" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html" - } + "openapi" : "3.0.0", + "info" : { + "description" : "Twitter API v2 available endpoints", + "version" : "2.100", + "title" : "Twitter API v2", + "termsOfService" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html", + "contact" : { + "name" : "Twitter Developers", + "url" : "https://developer.twitter.com/2/" }, - "paths" : { - "/2/compliance/jobs" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "List Compliance Jobs", - "description" : "Returns recent Compliance Jobs for a given job type and optional job status", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs" - }, - "operationId" : "listBatchComplianceJobs", - "parameters" : [ - { - "name" : "type", - "in" : "query", - "description" : "Type of Compliance Job to list.", - "required" : true, - "schema" : { - "type" : "string", - "enum" : [ - "tweets", - "users" - ] - }, - "style" : "form" + "license" : { + "name" : "Twitter Developer Agreement and Policy", + "url" : "https://developer.twitter.com/en/developer-terms/agreement-and-policy.html" + } + }, + "paths" : { + "/compliance/jobs" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "List Compliance Jobs", + "description" : "Returns recent Compliance Jobs for a given job type and optional job status", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs" + }, + "operationId" : "listBatchComplianceJobs", + "parameters" : [ + { + "name" : "type", + "in" : "query", + "description" : "Type of Compliance Job to list.", + "required" : true, + "schema" : { + "type" : "string", + "enum" : [ + "tweets", + "users" + ] }, - { - "name" : "status", - "in" : "query", - "description" : "Status of Compliance Job to list.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "created", - "in_progress", - "failed", - "complete" - ] - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "status", + "in" : "query", + "description" : "Status of Compliance Job to list.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "created", + "in_progress", + "failed", + "complete" + ] }, - { - "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ComplianceJobsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ComplianceJobsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } + } + }, + "post" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Create compliance job", + "description" : "Creates a compliance for the given job type", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/post-compliance-jobs" }, - "post" : { - "security" : [ - { - "BearerToken" : [ ] + "operationId" : "createBatchComplianceJob", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateComplianceJobRequest" + } } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Create compliance job", - "description" : "Creates a compliance for the given job type", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/post-compliance-jobs" }, - "operationId" : "createBatchComplianceJob", - "parameters" : [ ], - "requestBody" : { + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/CreateComplianceJobRequest" + "$ref" : "#/components/schemas/CreateComplianceJobResponse" } } - }, - "required" : true + } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/CreateComplianceJobResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/compliance/jobs/{id}" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Get Compliance Job", - "description" : "Returns a single Compliance Job by ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs-id" - }, - "operationId" : "getBatchComplianceJob", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the Compliance Job to retrieve.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/JobId" - }, - "style" : "simple" + } + }, + "/compliance/jobs/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Get Compliance Job", + "description" : "Returns a single Compliance Job by ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-compliance/api-reference/get-compliance-jobs-id" + }, + "operationId" : "getBatchComplianceJob", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Compliance Job to retrieve.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/JobId" }, - { - "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ComplianceJobsIdResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ComplianceJobFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ComplianceJobsIdResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_conversations" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] + } + }, + "/dm_conversations" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Create a new DM Conversation", + "description" : "Creates a new DM Conversation.", + "operationId" : "dmConversationIdCreate", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/CreateDmConversationRequest" + } } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Create a new DM Conversation", - "description" : "Creates a new DM Conversation.", - "operationId" : "dmConversationIdCreate", - "parameters" : [ ], - "requestBody" : { + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/CreateDmConversationRequest" + "$ref" : "#/components/schemas/CreateDmEventResponse" } } } }, - "responses" : { - "201" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/CreateDmEventResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_conversations/with/{participant_id}/dm_events" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Get DM Events for a DM Conversation", - "description" : "Returns DM Events for a DM Conversation", - "operationId" : "getDmConversationsWithParticipantIdDmEvents", - "parameters" : [ - { - "name" : "participant_id", - "in" : "path", - "description" : "The ID of the participant user for the One to One DM conversation.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" + } + }, + "/dm_conversations/with/{participant_id}/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events for a DM Conversation", + "description" : "Returns DM Events for a DM Conversation", + "operationId" : "getDmConversationsWithParticipantIdDmEvents", + "parameters" : [ + { + "name" : "participant_id", + "in" : "path", + "description" : "The ID of the participant user for the One to One DM conversation.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "name" : "event_types", - "in" : "query", - "description" : "The set of event_types to include in the results.", - "required" : false, - "schema" : { - "type" : "array", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "MessageCreate", - "ParticipantsJoin", - "ParticipantsLeave" - ] - }, - "default" : [ - "MessageCreate", - "ParticipantsLeave", - "ParticipantsJoin" - ], - "example" : [ + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "MessageCreate", + "ParticipantsJoin", "ParticipantsLeave" ] }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/DmEventFieldsParameter" - }, - { - "$ref" : "#/components/parameters/DmEventExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2DmConversationsWithParticipantIdDmEventsResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmConversationsWithParticipantIdDmEventsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_conversations/with/{participant_id}/messages" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.write", - "tweet.read", - "users.read" - ] + } + }, + "/dm_conversations/with/{participant_id}/messages" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Send a new message to a user", + "description" : "Creates a new message for a DM Conversation with a participant user by ID", + "operationId" : "dmConversationWithUserEventIdCreate", + "parameters" : [ + { + "name" : "participant_id", + "in" : "path", + "description" : "The ID of the recipient user that will receive the DM.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Send a new message to a user", - "description" : "Creates a new message for a DM Conversation with a participant user by ID", - "operationId" : "dmConversationWithUserEventIdCreate", - "parameters" : [ - { - "name" : "participant_id", - "in" : "path", - "description" : "The ID of the recipient user that will receive the DM.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/CreateMessageRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/CreateMessageRequest" + "$ref" : "#/components/schemas/CreateDmEventResponse" } } } }, - "responses" : { - "201" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/CreateDmEventResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_conversations/{dm_conversation_id}/messages" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.write", - "tweet.read", - "users.read" - ] + } + }, + "/dm_conversations/{dm_conversation_id}/messages" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Send a new message to a DM Conversation", + "description" : "Creates a new message for a DM Conversation specified by DM Conversation ID", + "operationId" : "dmConversationByIdEventIdCreate", + "parameters" : [ + { + "name" : "dm_conversation_id", + "in" : "path", + "description" : "The DM Conversation ID.", + "required" : true, + "schema" : { + "type" : "string" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Send a new message to a DM Conversation", - "description" : "Creates a new message for a DM Conversation specified by DM Conversation ID", - "operationId" : "dmConversationByIdEventIdCreate", - "parameters" : [ - { - "name" : "dm_conversation_id", - "in" : "path", - "description" : "The DM Conversation ID.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "type" : "string" - }, - "style" : "simple" + "$ref" : "#/components/schemas/CreateMessageRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/CreateMessageRequest" + "$ref" : "#/components/schemas/CreateDmEventResponse" } } } }, - "responses" : { - "201" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/CreateDmEventResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_conversations/{id}/dm_events" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.read", - "tweet.read", - "users.read" - ] + } + }, + "/dm_conversations/{id}/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events for a DM Conversation", + "description" : "Returns DM Events for a DM Conversation", + "operationId" : "getDmConversationsIdDmEvents", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The DM Conversation ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmConversationId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Get DM Events for a DM Conversation", - "description" : "Returns DM Events for a DM Conversation", - "operationId" : "getDmConversationsIdDmEvents", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The DM Conversation ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/DmConversationId" - }, - "style" : "simple" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "MessageCreate", + "ParticipantsJoin", + "ParticipantsLeave" + ] }, - "style" : "form" - }, - { - "name" : "event_types", - "in" : "query", - "description" : "The set of event_types to include in the results.", - "required" : false, - "schema" : { - "type" : "array", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "MessageCreate", - "ParticipantsJoin", - "ParticipantsLeave" - ] - }, - "default" : [ - "MessageCreate", - "ParticipantsLeave", - "ParticipantsJoin" - ], - "example" : [ - "MessageCreate", - "ParticipantsLeave" - ] - }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/DmEventFieldsParameter" - }, - { - "$ref" : "#/components/parameters/DmEventExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2DmConversationsIdDmEventsResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmConversationsIdDmEventsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_events" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Get recent DM Events", - "description" : "Returns recent DM Events across DM conversations", - "operationId" : "getDmEvents", - "parameters" : [ - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + } + }, + "/dm_events" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get recent DM Events", + "description" : "Returns recent DM Events across DM conversations", + "operationId" : "getDmEvents", + "parameters" : [ + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "name" : "event_types", - "in" : "query", - "description" : "The set of event_types to include in the results.", - "required" : false, - "schema" : { - "type" : "array", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "MessageCreate", - "ParticipantsJoin", - "ParticipantsLeave" - ] - }, - "default" : [ - "MessageCreate", - "ParticipantsLeave", - "ParticipantsJoin" - ], - "example" : [ + "style" : "form" + }, + { + "name" : "event_types", + "in" : "query", + "description" : "The set of event_types to include in the results.", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "MessageCreate", + "ParticipantsJoin", "ParticipantsLeave" ] }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/DmEventFieldsParameter" - }, - { - "$ref" : "#/components/parameters/DmEventExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "default" : [ + "MessageCreate", + "ParticipantsLeave", + "ParticipantsJoin" + ], + "example" : [ + "MessageCreate", + "ParticipantsLeave" + ] }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2DmEventsResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmEventsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/dm_events/{event_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.read", - "dm.write" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Delete Dm", - "description" : "Delete a Dm Event that you own.", - "operationId" : "dmEventDelete", - "parameters" : [ - { - "name" : "event_id", - "in" : "path", - "description" : "The ID of the direct-message event to delete.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/DmEventId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/DeleteDmResponse" - } - } - } + } + }, + "/dm_events/{event_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "dm.write" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Delete Dm", + "description" : "Delete a Dm Event that you own.", + "operationId" : "dmEventDelete", + "parameters" : [ + { + "name" : "event_id", + "in" : "path", + "description" : "The ID of the direct-message event to delete.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmEventId" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/DeleteDmResponse" } } } - } - }, - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "dm.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Direct Messages" - ], - "summary" : "Get DM Events by id", - "description" : "Returns DM Events by event id.", - "operationId" : "getDmEventsById", - "parameters" : [ - { - "name" : "event_id", - "in" : "path", - "description" : "dm event id.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/DmEventId" - }, - "style" : "simple" - }, - { - "$ref" : "#/components/parameters/DmEventFieldsParameter" - }, - { - "$ref" : "#/components/parameters/DmEventExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2DmEventsEventIdResponse" - } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/likes/compliance/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Likes Compliance stream", - "description" : "Streams 100% of compliance data for Users", - "operationId" : "getLikesComplianceStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Likes Compliance events will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "dm.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Direct Messages" + ], + "summary" : "Get DM Events by id", + "description" : "Returns DM Events by event id.", + "operationId" : "getDmEventsById", + "parameters" : [ + { + "name" : "event_id", + "in" : "path", + "description" : "dm event id.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/DmEventId" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Likes Compliance events will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/LikesComplianceStreamResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/DmEventFieldsParameter" + }, + { + "$ref" : "#/components/parameters/DmEventExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2DmEventsEventIdResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/likes/firehose/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Likes" - ], - "summary" : "Likes Firehose stream", - "description" : "Streams 100% of public Likes.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-likes-firehose-stream" - }, - "operationId" : "likesFirehoseStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 20, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + } + }, + "/likes/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Likes Compliance stream", + "description" : "Streams 100% of compliance data for Users", + "operationId" : "getLikesComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/LikeFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Likes Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/LikeExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Likes Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingLikeResponse" - } + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/LikesComplianceStreamResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } + } + }, + "x-twitter-streaming" : true + } + }, + "/likes/firehose/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Likes" + ], + "summary" : "Likes Firehose stream", + "description" : "Streams 100% of public Likes.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-likes-firehose-stream" + }, + "operationId" : "likesFirehoseStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" }, - "x-twitter-streaming" : true - } - }, - "/2/likes/sample10/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Likes" - ], - "summary" : "Likes Sample 10 stream", - "description" : "Streams 10% of public Likes.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/likes/firehose/api-reference/get-likes-sample10-stream" + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 20, + "format" : "int32" + }, + "style" : "form" }, - "operationId" : "likesSample10Stream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 2, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/LikeFieldsParameter" - }, - { - "$ref" : "#/components/parameters/LikeExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingLikeResponse" - } - } - } + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } - } - } - } + "style" : "form" }, - "x-twitter-streaming" : true - } - }, - "/2/lists" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.read", - "list.write", - "tweet.read", - "users.read" - ] + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Create List", - "description" : "Creates a new List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/post-lists" + "style" : "form" + }, + { + "$ref" : "#/components/parameters/LikeFieldsParameter" }, - "operationId" : "listIdCreate", - "parameters" : [ ], - "requestBody" : { + { + "$ref" : "#/components/parameters/LikeExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListCreateRequest" + "$ref" : "#/components/schemas/StreamingLikeResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListCreateResponse" - } - } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - } - } - } - }, - "/2/lists/{id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Delete List", - "description" : "Delete a List that you own.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/delete-lists-id" - }, - "operationId" : "listIdDelete", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List to delete.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListDeleteResponse" - } - } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } }, - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] + "x-twitter-streaming" : true + } + }, + "/likes/sample10/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Likes" + ], + "summary" : "Likes Sample 10 stream", + "description" : "Streams 10% of public Likes.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/likes/firehose/api-reference/get-likes-sample10-stream" + }, + "operationId" : "likesSample10Stream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "List lookup by List ID.", - "description" : "Returns a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-lists-id" - }, - "operationId" : "listIdGet", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/ListFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Likes will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/ListExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ListsIdResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/LikeFieldsParameter" + }, + { + "$ref" : "#/components/parameters/LikeExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingLikeResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } }, - "put" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Update List.", - "description" : "Update a List that you own.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/put-lists-id" - }, - "operationId" : "listIdUpdate", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List to modify.", - "required" : true, + "x-twitter-streaming" : true + } + }, + "/lists" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.read", + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Create List", + "description" : "Creates a new List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/post-lists" + }, + "operationId" : "listIdCreate", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/ListCreateRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListUpdateRequest" + "$ref" : "#/components/schemas/ListCreateResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListUpdateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/lists/{id}/followers" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that follow a List by the provided List ID", - "description" : "Returns a list of Users that follow a List by the provided List ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" - }, - "operationId" : "listGetFollowers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + } + }, + "/lists/{id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Delete List", + "description" : "Delete a List that you own.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/delete-lists-id" + }, + "operationId" : "listIdDelete", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to delete.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ListsIdFollowersResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListDeleteResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/lists/{id}/members" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that are members of a List by the provided List ID.", - "description" : "Returns a list of Users that are members of a List by the provided List ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" - }, - "operationId" : "listGetMembers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "List lookup by List ID.", + "description" : "Returns a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-lists-id" + }, + "operationId" : "listIdGet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ListsIdMembersResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] + } + }, + "put" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Update List.", + "description" : "Update a List that you own.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/manage-lists/api-reference/put-lists-id" + }, + "operationId" : "listIdUpdate", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to modify.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Add a List member", - "description" : "Causes a User to become a member of a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/post-lists-id-members" - }, - "operationId" : "listAddMember", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List for which to add a member.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/ListUpdateRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListAddUserRequest" + "$ref" : "#/components/schemas/ListUpdateResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListMutateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/lists/{id}/members/{user_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] + } + }, + "/lists/{id}/followers" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that follow a List by the provided List ID", + "description" : "Returns a list of Users that follow a List by the provided List ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" + }, + "operationId" : "listGetFollowers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Remove a List member", - "description" : "Causes a User to be removed from the members of a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/delete-lists-id-members-user_id" - }, - "operationId" : "listRemoveMember", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List to remove a member.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "name" : "user_id", - "in" : "path", - "description" : "The ID of User that will be removed from the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListMutateResponse" - } + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdFollowersResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/lists/{id}/tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "List Posts timeline by List ID.", - "description" : "Returns a list of Posts associated with the provided List ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-tweets/api-reference/get-lists-id-tweets" - }, - "operationId" : "listsIdTweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + } + }, + "/lists/{id}/members" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are members of a List by the provided List ID.", + "description" : "Returns a list of Users that are members of a List by the provided List ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" + }, + "operationId" : "listGetMembers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2ListsIdTweetsResponse" - } - } - } + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdMembersResponse" } } } - } - } - }, - "/2/openapi.json" : { - "get" : { - "tags" : [ - "General" - ], - "summary" : "Returns the OpenAPI Specification document.", - "description" : "Full OpenAPI Specification in JSON format. (See https://github.com/OAI/OpenAPI-Specification/blob/master/README.md)", - "operationId" : "getOpenApiSpec", - "parameters" : [ ], - "responses" : { - "200" : { - "description" : "The request was successful", - "content" : { - "application/json" : { - "schema" : { - "type" : "object" - } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/spaces" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Add a List member", + "description" : "Causes a User to become a member of a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/post-lists-id-members" + }, + "operationId" : "listAddMember", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List for which to add a member.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces" - ], - "summary" : "Space lookup up Space IDs", - "description" : "Returns a variety of information about the Spaces specified by the requested IDs", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces" - }, - "operationId" : "findSpacesByIds", - "parameters" : [ - { - "name" : "ids", - "in" : "query", - "description" : "The list of Space IDs to return.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "type" : "array", - "minItems" : 1, - "maxItems" : 100, - "items" : { - "type" : "string", - "description" : "The unique identifier of this Space.", - "pattern" : "^[a-zA-Z0-9]{1,13}$", - "example" : "1SLjjRYNejbKM" - } - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/SpaceFieldsParameter" - }, - { - "$ref" : "#/components/parameters/SpaceExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TopicFieldsParameter" + "$ref" : "#/components/schemas/ListAddUserRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesResponse" - } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListMutateResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/spaces/by/creator_ids" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces" - ], - "summary" : "Space lookup by their creators", - "description" : "Returns a variety of information about the Spaces created by the provided User IDs", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-by-creator-ids" - }, - "operationId" : "findSpacesByCreatorIds", - "parameters" : [ - { - "name" : "user_ids", - "in" : "query", - "description" : "The IDs of Users to search through.", - "required" : true, - "schema" : { - "type" : "array", - "minItems" : 1, - "maxItems" : 100, - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/SpaceFieldsParameter" - }, - { - "$ref" : "#/components/parameters/SpaceExpansionsParameter" + } + }, + "/lists/{id}/members/{user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Remove a List member", + "description" : "Causes a User to be removed from the members of a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/delete-lists-id-members-user_id" + }, + "operationId" : "listRemoveMember", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List to remove a member.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "simple" + }, + { + "name" : "user_id", + "in" : "path", + "description" : "The ID of User that will be removed from the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/TopicFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesByCreatorIdsResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListMutateResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/spaces/search" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces" - ], - "summary" : "Search for Spaces", - "description" : "Returns Spaces that match the provided query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/search/api-reference/get-spaces-search" - }, - "operationId" : "searchSpaces", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "The search query.", - "required" : true, - "example" : "crypto", - "schema" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 2048, - "example" : "crypto" - }, - "style" : "form" - }, - { - "name" : "state", - "in" : "query", - "description" : "The state of Spaces to search for.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "live", - "scheduled", - "all" - ], - "default" : "all" - }, - "style" : "form" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The number of results to return.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/SpaceFieldsParameter" + } + }, + "/lists/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "List Posts timeline by List ID.", + "description" : "Returns a list of Posts associated with the provided List ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-tweets/api-reference/get-lists-id-tweets" + }, + "operationId" : "listsIdTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "$ref" : "#/components/parameters/SpaceExpansionsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "$ref" : "#/components/parameters/TopicFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesSearchResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2ListsIdTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/spaces/{id}" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces" - ], - "summary" : "Space lookup by Space ID", - "description" : "Returns a variety of information about the Space specified by the requested ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id" - }, - "operationId" : "findSpaceById", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the Space to be retrieved.", - "required" : true, - "example" : "1YqKDqWqdPLsV", - "schema" : { - "type" : "string", - "description" : "The unique identifier of this Space.", - "pattern" : "^[a-zA-Z0-9]{1,13}$", - "example" : "1SLjjRYNejbKM" - }, - "style" : "simple" - }, - { - "$ref" : "#/components/parameters/SpaceFieldsParameter" - }, - { - "$ref" : "#/components/parameters/SpaceExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TopicFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesIdResponse" - } - } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "/openapi.json" : { + "get" : { + "tags" : [ + "General" + ], + "summary" : "Returns the OpenAPI Specification document.", + "description" : "Full OpenAPI Specification in JSON format. (See https://github.com/OAI/OpenAPI-Specification/blob/master/README.md)", + "operationId" : "getOpenApiSpec", + "parameters" : [ ], + "responses" : { + "200" : { + "description" : "The request was successful", + "content" : { + "application/json" : { + "schema" : { + "type" : "object" } } } } } - }, - "/2/spaces/{id}/buyers" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces", - "Tweets" - ], - "summary" : "Retrieve the list of Users who purchased a ticket to the given space", - "description" : "Retrieves the list of Users who purchased a ticket to the given space", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-buyers" - }, - "operationId" : "spaceBuyers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the Space to be retrieved.", - "required" : true, - "example" : "1YqKDqWqdPLsV", - "schema" : { + } + }, + "/spaces" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup up Space IDs", + "description" : "Returns a variety of information about the Spaces specified by the requested IDs", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces" + }, + "operationId" : "findSpacesByIds", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "The list of Space IDs to return.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { "type" : "string", "description" : "The unique identifier of this Space.", "pattern" : "^[a-zA-Z0-9]{1,13}$", "example" : "1SLjjRYNejbKM" - }, - "style" : "simple" + } }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesIdBuyersResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/spaces/{id}/tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "space.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Spaces", - "Tweets" - ], - "summary" : "Retrieve Posts from a Space.", - "description" : "Retrieves Posts shared in the specified Space.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-tweets" - }, - "operationId" : "spaceTweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the Space to be retrieved.", - "required" : true, - "example" : "1YqKDqWqdPLsV", - "schema" : { - "type" : "string", - "description" : "The unique identifier of this Space.", - "pattern" : "^[a-zA-Z0-9]{1,13}$", - "example" : "1SLjjRYNejbKM" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The number of Posts to fetch from the provided space. If not provided, the value will default to the maximum of 100.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100, - "example" : 25 - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + } + }, + "/spaces/by/creator_ids" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup by their creators", + "description" : "Returns a variety of information about the Spaces created by the provided User IDs", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-by-creator-ids" + }, + "operationId" : "findSpacesByCreatorIds", + "parameters" : [ + { + "name" : "user_ids", + "in" : "query", + "description" : "The IDs of Users to search through.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "$ref" : "#/components/schemas/UserId" + } }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2SpacesIdTweetsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesByCreatorIdsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/trends/by/woeid/{woeid}" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Trends" - ], - "summary" : "Trends", - "description" : "Returns the Trend associated with the supplied WoeId.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/trends/api-reference/get-trends-by-woeid" + } + }, + "/spaces/search" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Search for Spaces", + "description" : "Returns Spaces that match the provided query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/search/api-reference/get-spaces-search" + }, + "operationId" : "searchSpaces", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "The search query.", + "required" : true, + "example" : "crypto", + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 2048, + "example" : "crypto" + }, + "style" : "form" }, - "operationId" : "getTrends", - "parameters" : [ - { - "name" : "woeid", - "in" : "path", - "description" : "The WOEID of the place to lookup a trend for.", - "required" : true, - "example" : "2244994945", - "schema" : { - "type" : "integer", - "format" : "int32" - }, - "style" : "simple" + { + "name" : "state", + "in" : "query", + "description" : "The state of Spaces to search for.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "live", + "scheduled", + "all" + ], + "default" : "all" }, - { - "$ref" : "#/components/parameters/TrendFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TrendsByWoeidWoeidResponse" - } + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The number of results to return.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesSearchResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/spaces/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces" + ], + "summary" : "Space lookup by Space ID", + "description" : "Returns a variety of information about the Space specified by the requested ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id" + }, + "operationId" : "findSpaceById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Post lookup by Post IDs", - "description" : "Returns a variety of information about the Post specified by the requested ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets" - }, - "operationId" : "findTweetsById", - "parameters" : [ - { - "name" : "ids", - "in" : "query", - "description" : "A comma separated list of Post IDs. Up to 100 are allowed in a single request.", - "required" : true, - "schema" : { - "type" : "array", - "minItems" : 1, - "maxItems" : 100, - "items" : { - "$ref" : "#/components/schemas/TweetId" + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/SpaceFieldsParameter" + }, + { + "$ref" : "#/components/parameters/SpaceExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TopicFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesIdResponse" } - }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsResponse" - } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "tweet.write", - "users.read" - ] + } + } + }, + "/spaces/{id}/buyers" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces", + "Tweets" + ], + "summary" : "Retrieve the list of Users who purchased a ticket to the given space", + "description" : "Retrieves the list of Users who purchased a ticket to the given space", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-buyers" + }, + "operationId" : "spaceBuyers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "style" : "simple" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Creation of a Post", - "description" : "Causes the User to create a Post under the authorized account.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/post-tweets" + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" }, - "operationId" : "createTweet", - "parameters" : [ ], - "requestBody" : { + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/TweetCreateRequest" + "$ref" : "#/components/schemas/Get2SpacesIdBuyersResponse" } } - }, - "required" : true + } }, - "responses" : { - "201" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/TweetCreateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/compliance/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Posts Compliance stream", - "description" : "Streams 100% of compliance data for Posts", - "operationId" : "getTweetsComplianceStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 4, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post Compliance events will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + } + }, + "/spaces/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "space.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Spaces", + "Tweets" + ], + "summary" : "Retrieve Posts from a Space.", + "description" : "Retrieves Posts shared in the specified Space.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces/lookup/api-reference/get-spaces-id-tweets" + }, + "operationId" : "spaceTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Space to be retrieved.", + "required" : true, + "example" : "1YqKDqWqdPLsV", + "schema" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The number of Posts to fetch from the provided space. If not provided, the value will default to the maximum of 100.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100, + "example" : 25 }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Post Compliance events will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/TweetComplianceStreamResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2SpacesIdTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/tweets/counts/all" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Full archive search counts", - "description" : "Returns Post Counts that match a search query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" + } + }, + "/trends/by/woeid/{woeid}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Trends" + ], + "summary" : "Trends", + "description" : "Returns the Trend associated with the supplied WoeId.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/trends/api-reference/get-trends-by-woeid" + }, + "operationId" : "getTrends", + "parameters" : [ + { + "name" : "woeid", + "in" : "path", + "description" : "The WOEID of the place to lookup a trend for.", + "required" : true, + "example" : "2244994945", + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "style" : "simple" }, - "operationId" : "tweetCountsFullArchiveSearch", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", - "required" : true, - "schema" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 4096, - "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "since_id", - "in" : "query", - "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "until_id", - "in" : "query", - "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "next_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "granularity", - "in" : "query", - "description" : "The granularity for the search counts results.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "minute", - "hour", - "day" - ], - "default" : "hour" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/SearchCountFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsCountsAllResponse" - } + { + "$ref" : "#/components/parameters/TrendFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TrendsByWoeidWoeidResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/counts/recent" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Recent search counts", - "description" : "Returns Post Counts from the last 7 days that match a search query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/counts/api-reference/get-tweets-counts-recent" + } + }, + "/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] }, - "operationId" : "tweetCountsRecentSearch", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", - "required" : true, - "schema" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 4096, - "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "since_id", - "in" : "query", - "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "until_id", - "in" : "query", - "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", - "required" : false, - "schema" : { + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post lookup by Post IDs", + "description" : "Returns a variety of information about the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets" + }, + "operationId" : "findTweetsById", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A comma separated list of Post IDs. Up to 100 are allowed in a single request.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "next_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" + } }, - { - "name" : "granularity", - "in" : "query", - "description" : "The granularity for the search counts results.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "minute", - "hour", - "day" - ], - "default" : "hour" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/SearchCountFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsCountsRecentResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/tweets/firehose/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Firehose stream", - "description" : "Streams 100% of public Posts.", - "operationId" : "getTweetsFirehoseStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 20, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Creation of a Post", + "description" : "Causes the User to create a Post under the authorized account.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/post-tweets" + }, + "operationId" : "createTweet", + "parameters" : [ ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" + "$ref" : "#/components/schemas/TweetCreateRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } + }, + "required" : true + }, + "responses" : { + "201" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetCreateResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/tweets/firehose/stream/lang/en" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "English Language Firehose stream", - "description" : "Streams 100% of English Language public Posts.", - "operationId" : "getTweetsFirehoseStreamLangEn", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" + } + }, + "/tweets/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Posts Compliance stream", + "description" : "Streams 100% of compliance data for Posts", + "operationId" : "getTweetsComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 8, - "format" : "int32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 4, + "format" : "int32" }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Post Compliance events will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetComplianceStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/counts/all" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Full archive search counts", + "description" : "Returns Post Counts that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" + }, + "operationId" : "tweetCountsFullArchiveSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "granularity", + "in" : "query", + "description" : "The granularity for the search counts results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "minute", + "hour", + "day" + ], + "default" : "hour" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SearchCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsCountsAllResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/tweets/firehose/stream/lang/ja" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Japanese Language Firehose stream", - "description" : "Streams 100% of Japanese Language public Posts.", - "operationId" : "getTweetsFirehoseStreamLangJa", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" + } + }, + "/tweets/counts/recent" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Recent search counts", + "description" : "Returns Post Counts from the last 7 days that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/counts/api-reference/get-tweets-counts-recent" + }, + "operationId" : "tweetCountsRecentSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 2, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp (from most recent 7 days) from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } - } - } + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "granularity", + "in" : "query", + "description" : "The granularity for the search counts results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "minute", + "hour", + "day" + ], + "default" : "hour" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/SearchCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsCountsRecentResponse" } } } }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/firehose/stream/lang/ko" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Korean Language Firehose stream", - "description" : "Streams 100% of Korean Language public Posts.", - "operationId" : "getTweetsFirehoseStreamLangKo", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 2, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/tweets/firehose/stream/lang/pt" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Portuguese Language Firehose stream", - "description" : "Streams 100% of Portuguese Language public Posts.", - "operationId" : "getTweetsFirehoseStreamLangPt", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 2, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + } + }, + "/tweets/firehose/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Firehose stream", + "description" : "Streams 100% of public Posts.", + "operationId" : "getTweetsFirehoseStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 20, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/firehose/stream/lang/en" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "English Language Firehose stream", + "description" : "Streams 100% of English Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangEn", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/label/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Posts Label stream", - "description" : "Streams 100% of labeling events applied to Posts", - "operationId" : "getTweetsLabelStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 8, + "format" : "int32" }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post labels will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Post labels will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/TweetLabelStreamResponse" - } - } - } + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" } } } }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/sample/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Sample stream", - "description" : "Streams a deterministic 1% of public Posts.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/volume-streams/api-reference/get-tweets-sample-stream" - }, - "operationId" : "sampleStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/firehose/stream/lang/ja" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Japanese Language Firehose stream", + "description" : "Streams 100% of Japanese Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangJa", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/StreamingTweetResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/firehose/stream/lang/ko" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Korean Language Firehose stream", + "description" : "Streams 100% of Korean Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangKo", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" + }, + "style" : "form" }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/sample10/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Sample 10% stream", - "description" : "Streams a deterministic 10% of public Posts.", - "operationId" : "getTweetsSample10Stream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 2, - "format" : "int32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/firehose/stream/lang/pt" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Portuguese Language Firehose stream", + "description" : "Streams 100% of Portuguese Language public Posts.", + "operationId" : "getTweetsFirehoseStreamLangPt", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsSample10StreamResponse" - } - } - } + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" } } } }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/search/all" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Full-archive search", - "description" : "Returns Posts that match a search query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" - }, - "operationId" : "tweetsFullarchiveSearch", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", - "required" : true, - "schema" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 4096, - "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/label/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Posts Label stream", + "description" : "Streams 100% of labeling events applied to Posts", + "operationId" : "getTweetsLabelStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Post labels will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the Post labels will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "since_id", - "in" : "query", - "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetLabelStreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/sample/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Sample stream", + "description" : "Streams a deterministic 1% of public Posts.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/volume-streams/api-reference/get-tweets-sample-stream" + }, + "operationId" : "sampleStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "name" : "until_id", - "in" : "query", - "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/StreamingTweetResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/sample10/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Sample 10% stream", + "description" : "Streams a deterministic 10% of public Posts.", + "operationId" : "getTweetsSample10Stream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of search results to be returned by a request.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 10, - "maximum" : 500, - "format" : "int32", - "default" : 10 - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 2, + "format" : "int32" }, - { - "name" : "next_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "name" : "sort_order", - "in" : "query", - "description" : "This order in which to return results.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "recency", - "relevancy" - ] + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSample10StreamResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/tweets/search/all" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Full-archive search", + "description" : "Returns Posts that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-all" + }, + "operationId" : "tweetsFullarchiveSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of search results to be returned by a request.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 500, + "format" : "int32", + "default" : 10 + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "sort_order", + "in" : "query", + "description" : "This order in which to return results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "recency", + "relevancy" + ] }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsSearchAllResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchAllResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/search/recent" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Recent search", - "description" : "Returns Posts from the last 7 days that match a search query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-recent" - }, - "operationId" : "tweetsRecentSearch", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", - "required" : true, - "schema" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 4096, - "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", - "required" : false, - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "since_id", - "in" : "query", - "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "until_id", - "in" : "query", - "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of search results to be returned by a request.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 10, - "maximum" : 100, - "format" : "int32", - "default" : 10 - }, - "style" : "form" - }, - { - "name" : "next_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "sort_order", - "in" : "query", - "description" : "This order in which to return results.", - "required" : false, - "schema" : { - "type" : "string", - "enum" : [ - "recency", - "relevancy" - ] - }, - "style" : "form" + } + }, + "/tweets/search/recent" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Recent search", + "description" : "Returns Posts from the last 7 days that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/search/api-reference/get-tweets-search-recent" + }, + "operationId" : "tweetsRecentSearch", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "One query/rule/filter for matching Posts. Refer to https://t.co/rulelength to identify the max query length.", + "required" : true, + "schema" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 4096, + "example" : "(from:TwitterDev OR from:TwitterAPI) has:media -is:retweet" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The oldest UTC timestamp from which the Posts will be provided. Timestamp is in second granularity and is inclusive (i.e. 12:00:01 includes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The newest, most recent UTC timestamp to which the Posts will be provided. Timestamp is in second granularity and is exclusive (i.e. 12:00:01 excludes the first second of the minute).", + "required" : false, + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "style" : "form" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "Returns results with a Post ID greater than (that is, more recent than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "Returns results with a Post ID less than (that is, older than) the specified ID.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of search results to be returned by a request.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 100, + "format" : "int32", + "default" : 10 + }, + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "sort_order", + "in" : "query", + "description" : "This order in which to return results.", + "required" : false, + "schema" : { + "type" : "string", + "enum" : [ + "recency", + "relevancy" + ] }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsSearchRecentResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchRecentResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/search/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Filtered stream", - "description" : "Streams Posts matching the stream's active rule set.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream" - }, - "operationId" : "searchStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + } + }, + "/tweets/search/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Filtered stream", + "description" : "Streams Posts matching the stream's active rule set.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream" + }, + "operationId" : "searchStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/FilteredStreamingTweetResponse" - } - } - } + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/FilteredStreamingTweetResponse" } } } }, - "x-twitter-streaming" : true - } - }, - "/2/tweets/search/stream/rules" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Rules lookup", - "description" : "Returns rules from a User's active rule set. Users can fetch all of their rules or a subset, specified by the provided rule ids.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules" - }, - "operationId" : "getRules", - "parameters" : [ - { - "name" : "ids", - "in" : "query", - "description" : "A comma-separated list of Rule IDs.", - "required" : false, - "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/RuleId" + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } }, - "style" : "form" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32", - "default" : 1000 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This value is populated by passing the 'next_token' returned in a request to paginate through results.", - "required" : false, - "schema" : { - "type" : "string", - "minLength" : 16, - "maxLength" : 16 - }, - "style" : "form" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/RulesLookupResponse" - } - } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } }, - "post" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Add/Delete rules", - "description" : "Add or delete rules from a User's active rule set. Users can provide unique, optionally tagged rules to add. Users can delete their entire rule set or a subset specified by rule ids or values.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/post-tweets-search-stream-rules" + "x-twitter-streaming" : true + } + }, + "/tweets/search/stream/rules" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Rules lookup", + "description" : "Returns rules from a User's active rule set. Users can fetch all of their rules or a subset, specified by the provided rule ids.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules" + }, + "operationId" : "getRules", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A comma-separated list of Rule IDs.", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/RuleId" + } + }, + "style" : "form" }, - "operationId" : "addOrDeleteRules", - "parameters" : [ - { - "name" : "dry_run", - "in" : "query", - "description" : "Dry Run can be used with both the add and delete action, with the expected result given, but without actually taking any action in the system (meaning the end state will always be as it was when the request was submitted). This is particularly useful to validate rule changes.", - "required" : false, - "schema" : { - "type" : "boolean" - }, - "style" : "form" + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 1000 }, - { - "name" : "delete_all", - "in" : "query", - "description" : "Delete All can be used to delete all of the rules associated this client app, it should be specified with no other parameters. Once deleted, rules cannot be recovered.", - "required" : false, - "schema" : { - "type" : "boolean" - }, - "style" : "form" - } - ], - "requestBody" : { + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This value is populated by passing the 'next_token' returned in a request to paginate through results.", + "required" : false, + "schema" : { + "type" : "string", + "minLength" : 16, + "maxLength" : 16 + }, + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/AddOrDeleteRulesRequest" + "$ref" : "#/components/schemas/RulesLookupResponse" } } - }, - "required" : true + } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/AddOrDeleteRulesResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/tweets/search/stream/rules/counts" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "General" - ], - "summary" : "Rules Count", - "description" : "Returns the counts of rules from a User's active rule set, to reflect usage by project and application.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules-counts" + "post" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Add/Delete rules", + "description" : "Add or delete rules from a User's active rule set. Users can provide unique, optionally tagged rules to add. Users can delete their entire rule set or a subset specified by rule ids or values.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/post-tweets-search-stream-rules" + }, + "operationId" : "addOrDeleteRules", + "parameters" : [ + { + "name" : "dry_run", + "in" : "query", + "description" : "Dry Run can be used with both the add and delete action, with the expected result given, but without actually taking any action in the system (meaning the end state will always be as it was when the request was submitted). This is particularly useful to validate rule changes.", + "required" : false, + "schema" : { + "type" : "boolean" + }, + "style" : "form" }, - "operationId" : "getRuleCount", - "parameters" : [ - { - "$ref" : "#/components/parameters/RulesCountFieldsParameter" + { + "name" : "delete_all", + "in" : "query", + "description" : "Delete All can be used to delete all of the rules associated this client app, it should be specified with no other parameters. Once deleted, rules cannot be recovered.", + "required" : false, + "schema" : { + "type" : "boolean" + }, + "style" : "form" + } + ], + "requestBody" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/AddOrDeleteRulesRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsSearchStreamRulesCountsResponse" - } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/AddOrDeleteRulesResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/{id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "tweet.write", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Post delete by Post ID", - "description" : "Delete specified Post (in the path) by ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/delete-tweets-id" - }, - "operationId" : "deleteTweetById", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the Post to be deleted.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/TweetDeleteResponse" - } + } + }, + "/tweets/search/stream/rules/counts" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "General" + ], + "summary" : "Rules Count", + "description" : "Returns the counts of rules from a User's active rule set, to reflect usage by project and application.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/api-reference/get-tweets-search-stream-rules-counts" + }, + "operationId" : "getRuleCount", + "parameters" : [ + { + "$ref" : "#/components/parameters/RulesCountFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsSearchStreamRulesCountsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Post lookup by Post ID", - "description" : "Returns a variety of information about the Post specified by the requested ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets-id" - }, - "operationId" : "findTweetById", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "A single Post ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + } + } + }, + "/tweets/{id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post delete by Post ID", + "description" : "Delete specified Post (in the path) by ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/delete-tweets-id" + }, + "operationId" : "deleteTweetById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the Post to be deleted.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsIdResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetDeleteResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/tweets/{id}/liking_users" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "like.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that have liked the provided Post ID", - "description" : "Returns a list of Users that have liked the provided Post ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-tweets-id-liking_users" - }, - "operationId" : "tweetsIdLikingUsers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "A single Post ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Post lookup by Post ID", + "description" : "Returns a variety of information about the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup/api-reference/get-tweets-id" + }, + "operationId" : "findTweetById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsIdLikingUsersResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/{id}/quote_tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Retrieve Posts that quote a Post.", - "description" : "Returns a variety of information about each Post that quotes the Post specified by the requested ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/quote-tweets/api-reference/get-tweets-id-quote_tweets" - }, - "operationId" : "findTweetsThatQuoteATweet", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "A single Post ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results to be returned.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 10, - "maximum" : 100, - "format" : "int32", - "default" : 10 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "exclude", - "in" : "query", - "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", - "required" : false, - "schema" : { - "type" : "array", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "replies", - "retweets" - ] - }, - "example" : [ - "replies", - "retweets" - ] - }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + } + }, + "/tweets/{id}/liking_users" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that have liked the provided Post ID", + "description" : "Returns a list of Users that have liked the provided Post ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-tweets-id-liking_users" + }, + "operationId" : "tweetsIdLikingUsers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsIdQuoteTweetsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdLikingUsersResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/{id}/retweeted_by" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/tweets/{id}/quote_tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Retrieve Posts that quote a Post.", + "description" : "Returns a variety of information about each Post that quotes the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/quote-tweets/api-reference/get-tweets-id-quote_tweets" + }, + "operationId" : "findTweetsThatQuoteATweet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that have retweeted the provided Post ID", - "description" : "Returns a list of Users that have retweeted the provided Post ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweeted_by" - }, - "operationId" : "tweetsIdRetweetingUsers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "A single Post ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results to be returned.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 10, + "maximum" : 100, + "format" : "int32", + "default" : 10 }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ + "replies", + "retweets" + ] }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "example" : [ + "replies", + "retweets" + ] }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsIdRetweetedByResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdQuoteTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/tweets/{id}/retweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Retrieve Posts that repost a Post.", - "description" : "Returns a variety of information about each Post that has retweeted the Post specified by the requested ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweets" - }, - "operationId" : "findTweetsThatRetweetATweet", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "A single Post ID.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + } + }, + "/tweets/{id}/retweeted_by" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that have retweeted the provided Post ID", + "description" : "Returns a list of Users that have retweeted the provided Post ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweeted_by" + }, + "operationId" : "tweetsIdRetweetingUsers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2TweetsIdRetweetsResponse" - } - } - } + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } - } - } - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" } - } - }, - "/2/tweets/{tweet_id}/hidden" : { - "put" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.moderate.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Hide replies", - "description" : "Hides or unhides a reply to an owned conversation.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/hide-replies/api-reference/put-tweets-id-hidden" - }, - "operationId" : "hideReplyById", - "parameters" : [ - { - "name" : "tweet_id", - "in" : "path", - "description" : "The ID of the reply that you want to hide or unhide.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - } - ], - "requestBody" : { + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/TweetHideRequest" + "$ref" : "#/components/schemas/Get2TweetsIdRetweetedByResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/TweetHideResponse" - } - } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/usage/tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Usage" - ], - "summary" : "Post Usage", - "description" : "Returns the Post Usage.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/usage/tweets/api-reference/get-usage-tweets" + } + }, + "/tweets/{id}/retweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] }, - "operationId" : "getUsageTweets", - "parameters" : [ - { - "name" : "days", - "in" : "query", - "description" : "The number of days for which you need usage for.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 90, - "format" : "int32", - "default" : 7 - }, - "style" : "form" + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Retrieve Posts that repost a Post.", + "description" : "Returns a variety of information about each Post that has retweeted the Post specified by the requested ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/get-tweets-id-retweets" + }, + "operationId" : "findTweetsThatRetweetATweet", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "A single Post ID.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UsageFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsageTweetsResponse" - } + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2TweetsIdRetweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/tweets/{tweet_id}/hidden" : { + "put" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.moderate.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Hide replies", + "description" : "Hides or unhides a reply to an owned conversation.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/hide-replies/api-reference/put-tweets-id-hidden" + }, + "operationId" : "hideReplyById", + "parameters" : [ + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the reply that you want to hide or unhide.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User lookup by IDs", - "description" : "This endpoint returns information about Users. Specify Users by their ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users" - }, - "operationId" : "findUsersById", - "parameters" : [ - { - "name" : "ids", - "in" : "query", - "description" : "A list of User IDs, comma-separated. You can specify up to 100 IDs.", - "required" : true, - "example" : "2244994945,6253282,12", + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "type" : "array", - "minItems" : 1, - "maxItems" : 100, - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" + "$ref" : "#/components/schemas/TweetHideRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersResponse" - } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/TweetHideResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/by" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User lookup by usernames", - "description" : "This endpoint returns information about Users. Specify Users by their username.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by" - }, - "operationId" : "findUsersByUsername", - "parameters" : [ - { - "name" : "usernames", - "in" : "query", - "description" : "A list of usernames, comma-separated.", - "required" : true, - "schema" : { - "type" : "array", - "minItems" : 1, - "maxItems" : 100, - "items" : { - "type" : "string", - "description" : "The X handle (screen name) of this User.", - "pattern" : "^[A-Za-z0-9_]{1,15}$" - }, - "example" : "TwitterDev,TwitterAPI" - }, - "explode" : false, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + } + }, + "/usage/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Usage" + ], + "summary" : "Post Usage", + "description" : "Returns the Post Usage.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/usage/tweets/api-reference/get-usage-tweets" + }, + "operationId" : "getUsageTweets", + "parameters" : [ + { + "name" : "days", + "in" : "query", + "description" : "The number of days for which you need usage for.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 90, + "format" : "int32", + "default" : 7 }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersByResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UsageFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsageTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/by/username/{username}" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User lookup by username", - "description" : "This endpoint returns information about a User. Specify User by username.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by-username-username" - }, - "operationId" : "findUserByUsername", - "parameters" : [ - { - "name" : "username", - "in" : "path", - "description" : "A username.", - "required" : true, - "example" : "TwitterDev", - "schema" : { - "type" : "string", - "pattern" : "^[A-Za-z0-9_]{1,15}$" - }, - "style" : "simple" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + } + }, + "/users" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by IDs", + "description" : "This endpoint returns information about Users. Specify Users by their ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users" + }, + "operationId" : "findUsersById", + "parameters" : [ + { + "name" : "ids", + "in" : "query", + "description" : "A list of User IDs, comma-separated. You can specify up to 100 IDs.", + "required" : true, + "example" : "2244994945,6253282,12", + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { + "$ref" : "#/components/schemas/UserId" + } }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersByUsernameUsernameResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/compliance/stream" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - } - ], - "tags" : [ - "Compliance" - ], - "summary" : "Users Compliance stream", - "description" : "Streams 100% of compliance data for Users", - "operationId" : "getUsersComplianceStream", - "parameters" : [ - { - "name" : "backfill_minutes", - "in" : "query", - "description" : "The number of minutes of backfill requested.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 0, - "maximum" : 5, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "partition", - "in" : "query", - "description" : "The partition number.", - "required" : true, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 4, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the User Compliance events will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { + } + }, + "/users/by" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by usernames", + "description" : "This endpoint returns information about Users. Specify Users by their username.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by" + }, + "operationId" : "findUsersByUsername", + "parameters" : [ + { + "name" : "usernames", + "in" : "query", + "description" : "A list of usernames, comma-separated.", + "required" : true, + "schema" : { + "type" : "array", + "minItems" : 1, + "maxItems" : 100, + "items" : { "type" : "string", - "format" : "date-time" + "description" : "The X handle (screen name) of this User.", + "pattern" : "^[A-Za-z0-9_]{1,15}$" }, - "style" : "form" + "example" : "TwitterDev,TwitterAPI" }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the User Compliance events will be provided.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UserComplianceStreamResponse" - } + "explode" : false, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersByResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } - }, - "x-twitter-streaming" : true + } } - }, - "/2/users/me" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/users/by/username/{username}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by username", + "description" : "This endpoint returns information about a User. Specify User by username.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-by-username-username" + }, + "operationId" : "findUserByUsername", + "parameters" : [ + { + "name" : "username", + "in" : "path", + "description" : "A username.", + "required" : true, + "example" : "TwitterDev", + "schema" : { + "type" : "string", + "pattern" : "^[A-Za-z0-9_]{1,15}$" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User lookup me", - "description" : "This endpoint returns information about the requesting User.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-me" - }, - "operationId" : "findMyUser", - "parameters" : [ - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersMeResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersByUsernameUsernameResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/search" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/users/compliance/stream" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + } + ], + "tags" : [ + "Compliance" + ], + "summary" : "Users Compliance stream", + "description" : "Streams 100% of compliance data for Users", + "operationId" : "getUsersComplianceStream", + "parameters" : [ + { + "name" : "backfill_minutes", + "in" : "query", + "description" : "The number of minutes of backfill requested.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 0, + "maximum" : 5, + "format" : "int32" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User search", - "description" : "Returns Users that match a search query.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-search" - }, - "operationId" : "searchUserByQuery", - "parameters" : [ - { - "name" : "query", - "in" : "query", - "description" : "TThe the query string by which to query for users.", - "required" : true, - "example" : "someXUser", - "schema" : { - "$ref" : "#/components/schemas/UserSearchQuery" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "partition", + "in" : "query", + "description" : "The partition number.", + "required" : true, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 4, + "format" : "int32" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "next_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the User Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp from which the User Compliance events will be provided.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" + "style" : "form" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UserComplianceStreamResponse" + } + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersSearchResponse" - } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + } + }, + "x-twitter-streaming" : true + } + }, + "/users/me" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup me", + "description" : "This endpoint returns information about the requesting User.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-me" + }, + "operationId" : "findMyUser", + "parameters" : [ + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersMeResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "User lookup by ID", - "description" : "This endpoint returns information about a User. Specify User by ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-id" - }, - "operationId" : "findUserById", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + } + }, + "/users/search" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User search", + "description" : "Returns Users that match a search query.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-search" + }, + "operationId" : "searchUserByQuery", + "parameters" : [ + { + "name" : "query", + "in" : "query", + "description" : "TThe the query string by which to query for users.", + "required" : true, + "example" : "someXUser", + "schema" : { + "$ref" : "#/components/schemas/UserSearchQuery" + }, + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "style" : "form" + }, + { + "name" : "next_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results. The value used with the parameter is pulled directly from the response provided by the API, and should not be modified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersSearchResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/blocking" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "block.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that are blocked by provided User ID", - "description" : "Returns a list of Users that are blocked by the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/blocks/api-reference/get-users-blocking" - }, - "operationId" : "usersIdBlocking", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to return results.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + } + }, + "/users/{id}" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "User lookup by ID", + "description" : "This endpoint returns information about a User. Specify User by ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-id" + }, + "operationId" : "findUserById", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdBlockingResponse" - } + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/bookmarks" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "bookmark.read", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Bookmarks" - ], - "summary" : "Bookmarks by User", - "description" : "Returns Post objects that have been bookmarked by the requesting User", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/get-users-id-bookmarks" - }, - "operationId" : "getUsersIdBookmarks", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to return results.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + } + }, + "/users/{id}/blocking" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "block.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are blocked by provided User ID", + "description" : "Returns a list of Users that are blocked by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/blocks/api-reference/get-users-blocking" + }, + "operationId" : "usersIdBlocking", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdBookmarksResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdBlockingResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "bookmark.write", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Bookmarks" - ], - "summary" : "Add Post to Bookmarks", - "description" : "Adds a Post (ID in the body) to the requesting User's (in the path) bookmarks", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/post-users-id-bookmarks" - }, - "operationId" : "postUsersIdBookmarks", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to add bookmarks.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - } - ], - "requestBody" : { + } + } + }, + "/users/{id}/bookmarks" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.read", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Bookmarks by User", + "description" : "Returns Post objects that have been bookmarked by the requesting User", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/get-users-id-bookmarks" + }, + "operationId" : "getUsersIdBookmarks", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32" + }, + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/BookmarkAddRequest" + "$ref" : "#/components/schemas/Get2UsersIdBookmarksResponse" } } - }, - "required" : true + } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/BookmarkMutationResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/users/{id}/bookmarks/{tweet_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "bookmark.write", - "tweet.read", - "users.read" - ] - } - ], - "tags" : [ - "Bookmarks" - ], - "summary" : "Remove a bookmarked Post", - "description" : "Removes a Post from the requesting User's bookmarked Posts.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/delete-users-id-bookmarks-tweet_id" - }, - "operationId" : "usersIdBookmarksDelete", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User whose bookmark is to be removed.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.write", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Add Post to Bookmarks", + "description" : "Adds a Post (ID in the body) to the requesting User's (in the path) bookmarks", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/post-users-id-bookmarks" + }, + "operationId" : "postUsersIdBookmarks", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to add bookmarks.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "name" : "tweet_id", - "in" : "path", - "description" : "The ID of the Post that the source User is removing from bookmarks.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/BookmarkAddRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/BookmarkMutationResponse" - } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/BookmarkMutationResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/followed_lists" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Get User's Followed Lists", - "description" : "Returns a User's followed Lists.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/get-users-id-followed_lists" - }, - "operationId" : "userFollowedLists", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + } + }, + "/users/{id}/bookmarks/{tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "bookmark.write", + "tweet.read", + "users.read" + ] + } + ], + "tags" : [ + "Bookmarks" + ], + "summary" : "Remove a bookmarked Post", + "description" : "Removes a Post from the requesting User's bookmarked Posts.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/bookmarks/api-reference/delete-users-id-bookmarks-tweet_id" + }, + "operationId" : "usersIdBookmarksDelete", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User whose bookmark is to be removed.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the Post that the source User is removing from bookmarks.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/BookmarkMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "form" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/users/{id}/followed_lists" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get User's Followed Lists", + "description" : "Returns a User's followed Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/get-users-id-followed_lists" + }, + "operationId" : "userFollowedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/ListFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/ListExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdFollowedListsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowedListsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Follow a List", + "description" : "Causes a User to follow a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/post-users-id-followed-lists" }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] + "operationId" : "listUserFollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will follow the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Follow a List", - "description" : "Causes a User to follow a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/post-users-id-followed-lists" - }, - "operationId" : "listUserFollow", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that will follow the List.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + "$ref" : "#/components/schemas/ListFollowedRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListFollowedRequest" + "$ref" : "#/components/schemas/ListFollowedResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListFollowedResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/followed_lists/{list_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Unfollow a List", - "description" : "Causes a User to unfollow a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/delete-users-id-followed-lists-list_id" - }, - "operationId" : "listUserUnfollow", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that will unfollow the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + } + }, + "/users/{id}/followed_lists/{list_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Unfollow a List", + "description" : "Causes a User to unfollow a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-follows/api-reference/delete-users-id-followed-lists-list_id" + }, + "operationId" : "listUserUnfollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will unfollow the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "list_id", + "in" : "path", + "description" : "The ID of the List to unfollow.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "name" : "list_id", - "in" : "path", - "description" : "The ID of the List to unfollow.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListFollowedResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListFollowedResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/followers" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "follows.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Followers by User ID", - "description" : "Returns a list of Users who are followers of the specified User ID.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" - }, - "operationId" : "usersIdFollowers", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" + } + }, + "/users/{id}/followers" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "follows.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Followers by User ID", + "description" : "Returns a list of Users who are followers of the specified User ID.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-followers" + }, + "operationId" : "usersIdFollowers", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdFollowersResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowersResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/following" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "follows.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Following by User ID", - "description" : "Returns a list of Users that are being followed by the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-following" - }, - "operationId" : "usersIdFollowing", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken32" - }, - "style" : "form" + } + }, + "/users/{id}/following" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "follows.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Following by User ID", + "description" : "Returns a list of Users that are being followed by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/get-users-id-following" + }, + "operationId" : "usersIdFollowing", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken32" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdFollowingResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdFollowingResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } + } + }, + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "follows.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Follow User", + "description" : "Causes the User(in the path) to follow, or “request to follow” for protected Users, the target User. The User(in the path) must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/post-users-source_user_id-following" }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "follows.write", - "tweet.read", - "users.read" - ] + "operationId" : "usersIdFollow", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to follow the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Follow User", - "description" : "Causes the User(in the path) to follow, or “request to follow” for protected Users, the target User. The User(in the path) must match the User context authorizing the request", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/post-users-source_user_id-following" - }, - "operationId" : "usersIdFollow", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to follow the target User.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + "$ref" : "#/components/schemas/UsersFollowingCreateRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UsersFollowingCreateRequest" + "$ref" : "#/components/schemas/UsersFollowingCreateResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersFollowingCreateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/liked_tweets" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "like.read", - "tweet.read", - "users.read" - ] + } + }, + "/users/{id}/liked_tweets" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Returns Post objects liked by the provided User ID", + "description" : "Returns a list of Posts liked by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-users-id-liked_tweets" + }, + "operationId" : "usersIdLikedTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Returns Post objects liked by the provided User ID", - "description" : "Returns a list of Posts liked by the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/get-users-id-liked_tweets" - }, - "operationId" : "usersIdLikedTweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 5, - "maximum" : 100, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" - }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdLikedTweetsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdLikedTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/likes" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "like.write", - "tweet.read", - "users.read" - ] + } + }, + "/users/{id}/likes" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to like the specified Post", + "description" : "Causes the User (in the path) to like the specified Post. The User in the path must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/post-users-id-likes" + }, + "operationId" : "usersIdLike", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to like the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Causes the User (in the path) to like the specified Post", - "description" : "Causes the User (in the path) to like the specified Post. The User in the path must match the User context authorizing the request.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/post-users-id-likes" - }, - "operationId" : "usersIdLike", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to like the Post.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + "$ref" : "#/components/schemas/UsersLikesCreateRequest" + } } - ], - "requestBody" : { + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UsersLikesCreateRequest" + "$ref" : "#/components/schemas/UsersLikesCreateResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersLikesCreateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/likes/{tweet_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "like.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Causes the User (in the path) to unlike the specified Post", - "description" : "Causes the User (in the path) to unlike the specified Post. The User must match the User context authorizing the request", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/delete-users-id-likes-tweet_id" - }, - "operationId" : "usersIdUnlike", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to unlike the Post.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - }, - { - "name" : "tweet_id", - "in" : "path", - "description" : "The ID of the Post that the User is requesting to unlike.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersLikesDeleteResponse" - } - } - } + } + }, + "/users/{id}/likes/{tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "like.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to unlike the specified Post", + "description" : "Causes the User (in the path) to unlike the specified Post. The User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/likes/api-reference/delete-users-id-likes-tweet_id" + }, + "operationId" : "usersIdUnlike", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unlike the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "tweet_id", + "in" : "path", + "description" : "The ID of the Post that the User is requesting to unlike.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersLikesDeleteResponse" } } } - } - } - }, - "/2/users/{id}/list_memberships" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Get a User's List Memberships", - "description" : "Get a User's List Memberships.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" - }, - "operationId" : "getUserListMemberships", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/ListFieldsParameter" - }, - { - "$ref" : "#/components/parameters/ListExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdListMembershipsResponse" - } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/mentions" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "User mention timeline by User ID", - "description" : "Returns Post objects that mention username associated to the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-mentions" - }, - "operationId" : "usersIdMentions", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "since_id", - "in" : "query", - "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "until_id", - "in" : "query", - "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", - "required" : false, - "example" : "1346889436626259968", - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 5, - "maximum" : 100, - "format" : "int32" - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + } + }, + "/users/{id}/list_memberships" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's List Memberships", + "description" : "Get a User's List Memberships.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-members/api-reference/get-users-id-list_memberships" + }, + "operationId" : "getUserListMemberships", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdMentionsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdListMembershipsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/muting" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "mute.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Returns User objects that are muted by the provided User ID", - "description" : "Returns a list of Users that are muted by the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/get-users-muting" - }, - "operationId" : "usersIdMuting", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to return results.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + } + }, + "/users/{id}/mentions" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User mention timeline by User ID", + "description" : "Returns Post objects that mention username associated to the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-mentions" + }, + "operationId" : "usersIdMentions", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 1000, - "format" : "int32", - "default" : 100 - }, - "style" : "form" + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" }, - { - "$ref" : "#/components/parameters/UserExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" + }, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdMutingResponse" - } - } - } + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } - } - } - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" } - }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "mute.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Mute User by User ID.", - "description" : "Causes the User (in the path) to mute the target User. The User (in the path) must match the User context authorizing the request.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/post-users-user_id-muting" - }, - "operationId" : "usersIdMute", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to mute the target User.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - } - ], - "requestBody" : { + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/MuteUserRequest" + "$ref" : "#/components/schemas/Get2UsersIdMentionsResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/MuteUserMutationResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/owned_lists" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Get a User's Owned Lists.", - "description" : "Get a User's Owned Lists.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-users-id-owned_lists" - }, - "operationId" : "listUserOwnedLists", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32", - "default" : 100 - }, - "style" : "form" - }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get a specified 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationTokenLong" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/ListFieldsParameter" + } + }, + "/users/{id}/muting" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Returns User objects that are muted by the provided User ID", + "description" : "Returns a list of Users that are muted by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/get-users-muting" + }, + "operationId" : "usersIdMuting", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 1000, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/ListExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdOwnedListsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdMutingResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/users/{id}/pinned_lists" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.read", - "tweet.read", - "users.read" - ] + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Mute User by User ID.", + "description" : "Causes the User (in the path) to mute the target User. The User (in the path) must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/post-users-user_id-muting" + }, + "operationId" : "usersIdMute", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to mute the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Get a User's Pinned Lists", - "description" : "Get a User's Pinned Lists.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/get-users-id-pinned_lists" - }, - "operationId" : "listUserPinnedLists", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to return results.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + "$ref" : "#/components/schemas/MuteUserRequest" + } + } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/MuteUserMutationResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "simple" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/users/{id}/owned_lists" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's Owned Lists.", + "description" : "Get a User's Owned Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/list-lookup/api-reference/get-users-id-owned_lists" + }, + "operationId" : "listUserOwnedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "$ref" : "#/components/parameters/ListFieldsParameter" + "style" : "simple" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32", + "default" : 100 }, - { - "$ref" : "#/components/parameters/ListExpansionsParameter" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get a specified 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationTokenLong" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdPinnedListsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdOwnedListsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } + } + } + }, + "/users/{id}/pinned_lists" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.read", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Get a User's Pinned Lists", + "description" : "Get a User's Pinned Lists.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/get-users-id-pinned_lists" }, - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] + "operationId" : "listUserPinnedLists", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Pin a List", - "description" : "Causes a User to pin a List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/post-users-id-pinned-lists" - }, - "operationId" : "listUserPin", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that will pin the List.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - } - ], - "requestBody" : { + "style" : "simple" + }, + { + "$ref" : "#/components/parameters/ListFieldsParameter" + }, + { + "$ref" : "#/components/parameters/ListExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListPinnedRequest" + "$ref" : "#/components/schemas/Get2UsersIdPinnedListsResponse" } } - }, - "required" : true + } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListPinnedResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } }, - "/2/users/{id}/pinned_lists/{list_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "list.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Lists" - ], - "summary" : "Unpin a List", - "description" : "Causes a User to remove a pinned List.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/delete-users-id-pinned-lists-list_id" - }, - "operationId" : "listUserUnpin", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User for whom to return results.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Pin a List", + "description" : "Causes a User to pin a List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/post-users-id-pinned-lists" + }, + "operationId" : "listUserPin", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that will pin the List.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "name" : "list_id", - "in" : "path", - "description" : "The ID of the List to unpin.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ListId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/ListPinnedRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ListUnpinResponse" - } + }, + "required" : true + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ListPinnedResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/retweets" : { - "post" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "tweet.write", - "users.read" - ] + } + }, + "/users/{id}/pinned_lists/{list_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "list.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Lists" + ], + "summary" : "Unpin a List", + "description" : "Causes a User to remove a pinned List.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists/pinned-lists/api-reference/delete-users-id-pinned-lists-list_id" + }, + "operationId" : "listUserUnpin", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User for whom to return results.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "list_id", + "in" : "path", + "description" : "The ID of the List to unpin.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/ListId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Causes the User (in the path) to repost the specified Post.", - "description" : "Causes the User (in the path) to repost the specified Post. The User in the path must match the User context authorizing the request.", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/post-users-id-retweets" - }, - "operationId" : "usersIdRetweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to repost the Post.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" - } - ], - "requestBody" : { + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/UsersRetweetsCreateRequest" + "$ref" : "#/components/schemas/ListUnpinResponse" } } } }, - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersRetweetsCreateResponse" - } + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" } - } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/retweets/{source_tweet_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "tweet.write", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "Causes the User (in the path) to unretweet the specified Post", - "description" : "Causes the User (in the path) to unretweet the specified Post. The User must match the User context authorizing the request", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/delete-users-id-retweets-tweet_id" - }, - "operationId" : "usersIdUnretweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to repost the Post.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + } + }, + "/users/{id}/retweets" : { + "post" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to repost the specified Post.", + "description" : "Causes the User (in the path) to repost the specified Post. The User in the path must match the User context authorizing the request.", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/post-users-id-retweets" + }, + "operationId" : "usersIdRetweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to repost the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" }, - { - "name" : "source_tweet_id", - "in" : "path", - "description" : "The ID of the Post that the User is requesting to unretweet.", - "required" : true, + "style" : "simple" + } + ], + "requestBody" : { + "content" : { + "application/json" : { "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "simple" + "$ref" : "#/components/schemas/UsersRetweetsCreateRequest" + } } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersRetweetsDeleteResponse" - } + } + }, + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersRetweetsCreateResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/timelines/reverse_chronological" : { - "get" : { - "security" : [ - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] + } + }, + "/users/{id}/retweets/{source_tweet_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "tweet.write", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "Causes the User (in the path) to unretweet the specified Post", + "description" : "Causes the User (in the path) to unretweet the specified Post. The User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/delete-users-id-retweets-tweet_id" + }, + "operationId" : "usersIdUnretweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to repost the Post.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "source_tweet_id", + "in" : "path", + "description" : "The ID of the Post that the User is requesting to unretweet.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "User home timeline by User ID", - "description" : "Returns Post objects that appears in the provided User ID's home timeline", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-reverse-chronological" - }, - "operationId" : "usersIdTimeline", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the authenticated source User to list Reverse Chronological Timeline Posts of.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersRetweetsDeleteResponse" + } + } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } }, - "style" : "simple" + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + } + } + } + }, + "/users/{id}/timelines/reverse_chronological" : { + "get" : { + "security" : [ + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User home timeline by User ID", + "description" : "Returns Post objects that appears in the provided User ID's home timeline", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-reverse-chronological" + }, + "operationId" : "usersIdTimeline", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the authenticated source User to list Reverse Chronological Timeline Posts of.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "example" : "791775337160081409", + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "since_id", - "in" : "query", - "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", - "required" : false, - "example" : "791775337160081409", - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" - }, - { - "name" : "until_id", - "in" : "query", - "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", - "required" : false, - "example" : "1346889436626259968", - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 1, - "maximum" : 100, - "format" : "int32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 1, + "maximum" : 100, + "format" : "int32" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "name" : "exclude", - "in" : "query", - "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", - "required" : false, - "schema" : { - "type" : "array", - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "replies", - "retweets" - ] - }, - "example" : [ + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "replies", "retweets" ] }, - "explode" : false, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "example" : [ + "replies", + "retweets" + ] }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "explode" : false, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdTimelinesReverseChronologicalResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdTimelinesReverseChronologicalResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{id}/tweets" : { - "get" : { - "security" : [ - { - "BearerToken" : [ ] - }, - { - "OAuth2UserToken" : [ - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Tweets" - ], - "summary" : "User Posts timeline by User ID", - "description" : "Returns a list of Posts authored by the provided User ID", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-tweets" - }, - "operationId" : "usersIdTweets", - "parameters" : [ - { - "name" : "id", - "in" : "path", - "description" : "The ID of the User to lookup.", - "required" : true, - "example" : "2244994945", - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" + } + }, + "/users/{id}/tweets" : { + "get" : { + "security" : [ + { + "BearerToken" : [ ] + }, + { + "OAuth2UserToken" : [ + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Tweets" + ], + "summary" : "User Posts timeline by User ID", + "description" : "Returns a list of Posts authored by the provided User ID", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-tweets" + }, + "operationId" : "usersIdTweets", + "parameters" : [ + { + "name" : "id", + "in" : "path", + "description" : "The ID of the User to lookup.", + "required" : true, + "example" : "2244994945", + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "name" : "since_id", - "in" : "query", - "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", - "required" : false, - "example" : "791775337160081409", - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" + "style" : "simple" + }, + { + "name" : "since_id", + "in" : "query", + "description" : "The minimum Post ID to be included in the result set. This parameter takes precedence over start_time if both are specified.", + "required" : false, + "example" : "791775337160081409", + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "until_id", - "in" : "query", - "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", - "required" : false, - "example" : "1346889436626259968", - "schema" : { - "$ref" : "#/components/schemas/TweetId" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "until_id", + "in" : "query", + "description" : "The maximum Post ID to be included in the result set. This parameter takes precedence over end_time if both are specified.", + "required" : false, + "example" : "1346889436626259968", + "schema" : { + "$ref" : "#/components/schemas/TweetId" }, - { - "name" : "max_results", - "in" : "query", - "description" : "The maximum number of results.", - "required" : false, - "schema" : { - "type" : "integer", - "minimum" : 5, - "maximum" : 100, - "format" : "int32" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "max_results", + "in" : "query", + "description" : "The maximum number of results.", + "required" : false, + "schema" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 100, + "format" : "int32" }, - { - "name" : "pagination_token", - "in" : "query", - "description" : "This parameter is used to get the next 'page' of results.", - "required" : false, - "schema" : { - "$ref" : "#/components/schemas/PaginationToken36" - }, - "style" : "form" + "style" : "form" + }, + { + "name" : "pagination_token", + "in" : "query", + "description" : "This parameter is used to get the next 'page' of results.", + "required" : false, + "schema" : { + "$ref" : "#/components/schemas/PaginationToken36" }, - { - "name" : "exclude", - "in" : "query", - "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", - "required" : false, - "schema" : { - "type" : "array", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "replies", - "retweets" - ] - }, - "example" : [ + "style" : "form" + }, + { + "name" : "exclude", + "in" : "query", + "description" : "The set of entities to exclude (e.g. 'replies' or 'retweets').", + "required" : false, + "schema" : { + "type" : "array", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "replies", "retweets" ] }, - "explode" : false, - "style" : "form" - }, - { - "name" : "start_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-01T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "name" : "end_time", - "in" : "query", - "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", - "required" : false, - "example" : "2021-02-14T18:40:40.000Z", - "schema" : { - "type" : "string", - "format" : "date-time" - }, - "style" : "form" - }, - { - "$ref" : "#/components/parameters/TweetFieldsParameter" - }, - { - "$ref" : "#/components/parameters/TweetExpansionsParameter" - }, - { - "$ref" : "#/components/parameters/MediaFieldsParameter" + "example" : [ + "replies", + "retweets" + ] }, - { - "$ref" : "#/components/parameters/PollFieldsParameter" + "explode" : false, + "style" : "form" + }, + { + "name" : "start_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The earliest UTC timestamp from which the Posts will be provided. The since_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-01T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/UserFieldsParameter" + "style" : "form" + }, + { + "name" : "end_time", + "in" : "query", + "description" : "YYYY-MM-DDTHH:mm:ssZ. The latest UTC timestamp to which the Posts will be provided. The until_id parameter takes precedence if it is also specified.", + "required" : false, + "example" : "2021-02-14T18:40:40.000Z", + "schema" : { + "type" : "string", + "format" : "date-time" }, - { - "$ref" : "#/components/parameters/PlaceFieldsParameter" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Get2UsersIdTweetsResponse" - } + "style" : "form" + }, + { + "$ref" : "#/components/parameters/TweetFieldsParameter" + }, + { + "$ref" : "#/components/parameters/TweetExpansionsParameter" + }, + { + "$ref" : "#/components/parameters/MediaFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PollFieldsParameter" + }, + { + "$ref" : "#/components/parameters/UserFieldsParameter" + }, + { + "$ref" : "#/components/parameters/PlaceFieldsParameter" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Get2UsersIdTweetsResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{source_user_id}/following/{target_user_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "follows.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Unfollow User", - "description" : "Causes the source User to unfollow the target User. The source User must match the User context authorizing the request", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/delete-users-source_id-following" - }, - "operationId" : "usersIdUnfollow", - "parameters" : [ - { - "name" : "source_user_id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to unfollow the target User.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + } + }, + "/users/{source_user_id}/following/{target_user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "follows.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Unfollow User", + "description" : "Causes the source User to unfollow the target User. The source User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/delete-users-source_id-following" + }, + "operationId" : "usersIdUnfollow", + "parameters" : [ + { + "name" : "source_user_id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unfollow the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "target_user_id", + "in" : "path", + "description" : "The ID of the User that the source User is requesting to unfollow.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "name" : "target_user_id", - "in" : "path", - "description" : "The ID of the User that the source User is requesting to unfollow.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/UsersFollowingDeleteResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/UsersFollowingDeleteResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } - }, - "/2/users/{source_user_id}/muting/{target_user_id}" : { - "delete" : { - "security" : [ - { - "OAuth2UserToken" : [ - "mute.write", - "tweet.read", - "users.read" - ] - }, - { - "UserToken" : [ ] - } - ], - "tags" : [ - "Users" - ], - "summary" : "Unmute User by User ID", - "description" : "Causes the source User to unmute the target User. The source User must match the User context authorizing the request", - "externalDocs" : { - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/delete-users-user_id-muting" - }, - "operationId" : "usersIdUnmute", - "parameters" : [ - { - "name" : "source_user_id", - "in" : "path", - "description" : "The ID of the authenticated source User that is requesting to unmute the target User.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" - }, - "style" : "simple" + } + }, + "/users/{source_user_id}/muting/{target_user_id}" : { + "delete" : { + "security" : [ + { + "OAuth2UserToken" : [ + "mute.write", + "tweet.read", + "users.read" + ] + }, + { + "UserToken" : [ ] + } + ], + "tags" : [ + "Users" + ], + "summary" : "Unmute User by User ID", + "description" : "Causes the source User to unmute the target User. The source User must match the User context authorizing the request", + "externalDocs" : { + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/mutes/api-reference/delete-users-user_id-muting" + }, + "operationId" : "usersIdUnmute", + "parameters" : [ + { + "name" : "source_user_id", + "in" : "path", + "description" : "The ID of the authenticated source User that is requesting to unmute the target User.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserIdMatchesAuthenticatedUser" + }, + "style" : "simple" + }, + { + "name" : "target_user_id", + "in" : "path", + "description" : "The ID of the User that the source User is requesting to unmute.", + "required" : true, + "schema" : { + "$ref" : "#/components/schemas/UserId" }, - { - "name" : "target_user_id", - "in" : "path", - "description" : "The ID of the User that the source User is requesting to unmute.", - "required" : true, - "schema" : { - "$ref" : "#/components/schemas/UserId" - }, - "style" : "simple" - } - ], - "responses" : { - "200" : { - "description" : "The request has succeeded.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/MuteUserMutationResponse" - } + "style" : "simple" + } + ], + "responses" : { + "200" : { + "description" : "The request has succeeded.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/MuteUserMutationResponse" } } - }, - "default" : { - "description" : "The request has failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/Error" - } - }, - "application/problem+json" : { - "schema" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "default" : { + "description" : "The request has failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/Error" + } + }, + "application/problem+json" : { + "schema" : { + "$ref" : "#/components/schemas/Problem" } } } } } } + } + }, + "servers" : [ + { + "description" : "Twitter API", + "url" : "https://api.twitter.com/2" + } + ], + "tags" : [ + { + "name" : "Bookmarks", + "description" : "Endpoints related to retrieving, managing bookmarks of a user", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/bookmarks" + } }, - "servers" : [ - { - "description" : "Twitter API", - "url" : "https://api.twitter.com" + { + "name" : "Compliance", + "description" : "Endpoints related to keeping X data in your systems compliant", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-tweet/introduction" } - ], - "tags" : [ - { - "name" : "Bookmarks", - "description" : "Endpoints related to retrieving, managing bookmarks of a user", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/bookmarks" - } + }, + { + "name" : "Direct Messages", + "description" : "Endpoints related to retrieving, managing Direct Messages", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/direct-messages" + } + }, + { + "name" : "General", + "description" : "Miscellaneous endpoints for general API functionality", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api" + } + }, + { + "name" : "Lists", + "description" : "Endpoints related to retrieving, managing Lists", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/lists" + } + }, + { + "name" : "Spaces", + "description" : "Endpoints related to retrieving, managing Spaces", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces" + } + }, + { + "name" : "Tweets", + "description" : "Endpoints related to retrieving, searching, and modifying Tweets", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup" + } + }, + { + "name" : "Users", + "description" : "Endpoints related to retrieving, managing relationships of Users", + "externalDocs" : { + "description" : "Find out more", + "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup" + } + } + ], + "components" : { + "securitySchemes" : { + "BearerToken" : { + "type" : "http", + "scheme" : "bearer" }, - { - "name" : "Compliance", - "description" : "Endpoints related to keeping X data in your systems compliant", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/compliance/batch-tweet/introduction" + "OAuth2UserToken" : { + "type" : "oauth2", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://api.twitter.com/2/oauth2/authorize", + "tokenUrl" : "https://api.twitter.com/2/oauth2/token", + "scopes" : { + "block.read" : "Accounts you’ve blocked.", + "bookmark.read" : "Allows an app to read bookmarked Tweets", + "bookmark.write" : "Allows an app to create and delete bookmarks", + "dm.read" : "All your Direct Messages", + "dm.write" : "Send and manage Direct Messages for you", + "follows.read" : "People who follow you and people who you follow.", + "follows.write" : "Follow and unfollow people for you.", + "like.read" : "Tweets you’ve liked and likes you can view.", + "like.write" : "Like and un-like Tweets for you.", + "list.read" : "Lists, list members, and list followers of lists you’ve created or are a member of, including private lists.", + "list.write" : "Create and manage Lists for you.", + "mute.read" : "Accounts you’ve muted.", + "mute.write" : "Mute and unmute accounts for you.", + "offline.access" : "App can request refresh token.", + "space.read" : "Access all of the Spaces you can see.", + "tweet.moderate.write" : "Hide and unhide replies to your Tweets.", + "tweet.read" : "All the Tweets you can see, including Tweets from protected accounts.", + "tweet.write" : "Tweet and retweet for you.", + "users.read" : "Any account you can see, including protected accounts. Any account you can see, including protected accounts." + } + } } }, - { - "name" : "Direct Messages", - "description" : "Endpoints related to retrieving, managing Direct Messages", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/direct-messages" - } + "UserToken" : { + "type" : "http", + "scheme" : "OAuth" + } + }, + "schemas" : { + "AddOrDeleteRulesRequest" : { + "oneOf" : [ + { + "$ref" : "#/components/schemas/AddRulesRequest" + }, + { + "$ref" : "#/components/schemas/DeleteRulesRequest" + } + ] }, - { - "name" : "General", - "description" : "Miscellaneous endpoints for general API functionality", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api" + "AddOrDeleteRulesResponse" : { + "type" : "object", + "description" : "A response from modifying user-specified stream filtering rules.", + "required" : [ + "meta" + ], + "properties" : { + "data" : { + "type" : "array", + "description" : "All user-specified stream filtering rules that were created.", + "items" : { + "$ref" : "#/components/schemas/Rule" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "$ref" : "#/components/schemas/RulesResponseMetadata" + } } }, - { - "name" : "Lists", - "description" : "Endpoints related to retrieving, managing Lists", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/lists" + "AddRulesRequest" : { + "type" : "object", + "description" : "A request to add a user-specified stream filtering rule.", + "required" : [ + "add" + ], + "properties" : { + "add" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/RuleNoId" + } + } } }, - { - "name" : "Spaces", - "description" : "Endpoints related to retrieving, managing Spaces", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/spaces" - } + "Aggregate" : { + "type" : "integer", + "description" : "The sum of results returned in this response.", + "format" : "int32" }, - { - "name" : "Tweets", - "description" : "Endpoints related to retrieving, searching, and modifying Tweets", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/tweets/lookup" + "AllProjectClientApps" : { + "type" : "array", + "description" : "Client App Rule Counts for all applications in the project", + "items" : { + "$ref" : "#/components/schemas/AppRulesCount" } }, - { - "name" : "Users", - "description" : "Endpoints related to retrieving, managing relationships of Users", - "externalDocs" : { - "description" : "Find out more", - "url" : "https://developer.twitter.com/en/docs/twitter-api/users/lookup" - } - } - ], - "components" : { - "securitySchemes" : { - "BearerToken" : { - "type" : "http", - "scheme" : "bearer" - }, - "OAuth2UserToken" : { - "type" : "oauth2", - "flows" : { - "authorizationCode" : { - "authorizationUrl" : "https://api.twitter.com/2/oauth2/authorize", - "tokenUrl" : "https://api.twitter.com/2/oauth2/token", - "scopes" : { - "block.read" : "Accounts you’ve blocked.", - "bookmark.read" : "Allows an app to read bookmarked Tweets", - "bookmark.write" : "Allows an app to create and delete bookmarks", - "dm.read" : "All your Direct Messages", - "dm.write" : "Send and manage Direct Messages for you", - "follows.read" : "People who follow you and people who you follow.", - "follows.write" : "Follow and unfollow people for you.", - "like.read" : "Tweets you’ve liked and likes you can view.", - "like.write" : "Like and un-like Tweets for you.", - "list.read" : "Lists, list members, and list followers of lists you’ve created or are a member of, including private lists.", - "list.write" : "Create and manage Lists for you.", - "mute.read" : "Accounts you’ve muted.", - "mute.write" : "Mute and unmute accounts for you.", - "offline.access" : "App can request refresh token.", - "space.read" : "Access all of the Spaces you can see.", - "tweet.moderate.write" : "Hide and unhide replies to your Tweets.", - "tweet.read" : "All the Tweets you can see, including Tweets from protected accounts.", - "tweet.write" : "Tweet and retweet for you.", - "users.read" : "Any account you can see, including protected accounts. Any account you can see, including protected accounts." - } - } - } - }, - "UserToken" : { - "type" : "http", - "scheme" : "OAuth" - } - }, - "schemas" : { - "AddOrDeleteRulesRequest" : { - "oneOf" : [ - { - "$ref" : "#/components/schemas/AddRulesRequest" - }, - { - "$ref" : "#/components/schemas/DeleteRulesRequest" - } - ] - }, - "AddOrDeleteRulesResponse" : { - "type" : "object", - "description" : "A response from modifying user-specified stream filtering rules.", - "required" : [ - "meta" - ], - "properties" : { - "data" : { - "type" : "array", - "description" : "All user-specified stream filtering rules that were created.", - "items" : { - "$ref" : "#/components/schemas/Rule" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + "AnimatedGif" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "preview_image_url" : { + "type" : "string", + "format" : "uri" + }, + "variants" : { + "$ref" : "#/components/schemas/Variants" } - }, - "meta" : { - "$ref" : "#/components/schemas/RulesResponseMetadata" } } - }, - "AddRulesRequest" : { - "type" : "object", - "description" : "A request to add a user-specified stream filtering rule.", - "required" : [ - "add" - ], - "properties" : { - "add" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/RuleNoId" - } - } + ] + }, + "AppRulesCount" : { + "type" : "object", + "description" : "A count of user-provided stream filtering rules at the client application level.", + "properties" : { + "client_app_id" : { + "$ref" : "#/components/schemas/ClientAppId" + }, + "rule_count" : { + "type" : "integer", + "description" : "Number of rules for client application", + "format" : "int32" } - }, - "Aggregate" : { - "type" : "integer", - "description" : "The sum of results returned in this response.", - "format" : "int32" - }, - "AllProjectClientApps" : { - "type" : "array", - "description" : "Client App Rule Counts for all applications in the project", - "items" : { - "$ref" : "#/components/schemas/AppRulesCount" + } + }, + "BookmarkAddRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" } - }, - "AnimatedGif" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/Media" - }, - { - "type" : "object", - "properties" : { - "preview_image_url" : { - "type" : "string", - "format" : "uri" - }, - "variants" : { - "$ref" : "#/components/schemas/Variants" - } + } + }, + "BookmarkMutationResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "bookmarked" : { + "type" : "boolean" } } - ] - }, - "AppRulesCount" : { - "type" : "object", - "description" : "A count of user-provided stream filtering rules at the client application level.", - "properties" : { - "client_app_id" : { - "$ref" : "#/components/schemas/ClientAppId" - }, - "rule_count" : { - "type" : "integer", - "description" : "Number of rules for client application", - "format" : "int32" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "BookmarkAddRequest" : { - "type" : "object", - "required" : [ - "tweet_id" - ], - "properties" : { - "tweet_id" : { - "$ref" : "#/components/schemas/TweetId" + } + }, + "CashtagEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/CashtagFields" + } + ] + }, + "CashtagFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a Cashtag, and its start and end position within the text.", + "required" : [ + "tag" + ], + "properties" : { + "tag" : { + "type" : "string", + "example" : "TWTR" + } + } + }, + "ClientAppId" : { + "type" : "string", + "description" : "The ID of the client application", + "minLength" : 1, + "maxLength" : 19 + }, + "ClientAppUsage" : { + "type" : "object", + "description" : "Usage per client app", + "properties" : { + "client_app_id" : { + "type" : "string", + "description" : "The unique identifier for this project", + "format" : "^[0-9]{1,19}$" + }, + "usage" : { + "type" : "array", + "description" : "The usage value", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UsageFields" } + }, + "usage_result_count" : { + "type" : "integer", + "description" : "The number of results returned", + "format" : "int32" } - }, - "BookmarkMutationResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "bookmarked" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "ClientDisconnectedProblem" : { + "description" : "Your client has gone away.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "ClientForbiddenProblem" : { + "description" : "A problem that indicates your client is forbidden from making this request.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "reason" : { + "type" : "string", + "enum" : [ + "official-client-forbidden", + "client-not-enrolled" + ] + }, + "registration_url" : { + "type" : "string", + "format" : "uri" } } } - }, - "CashtagEntity" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" - }, - { - "$ref" : "#/components/schemas/CashtagFields" - } - ] - }, - "CashtagFields" : { - "type" : "object", - "description" : "Represent the portion of text recognized as a Cashtag, and its start and end position within the text.", - "required" : [ - "tag" - ], - "properties" : { - "tag" : { - "type" : "string", - "example" : "TWTR" - } + ] + }, + "ComplianceJob" : { + "type" : "object", + "required" : [ + "id", + "type", + "created_at", + "upload_url", + "download_url", + "upload_expires_at", + "download_expires_at", + "status" + ], + "properties" : { + "created_at" : { + "$ref" : "#/components/schemas/CreatedAt" + }, + "download_expires_at" : { + "$ref" : "#/components/schemas/DownloadExpiration" + }, + "download_url" : { + "$ref" : "#/components/schemas/DownloadUrl" + }, + "id" : { + "$ref" : "#/components/schemas/JobId" + }, + "name" : { + "$ref" : "#/components/schemas/ComplianceJobName" + }, + "status" : { + "$ref" : "#/components/schemas/ComplianceJobStatus" + }, + "type" : { + "$ref" : "#/components/schemas/ComplianceJobType" + }, + "upload_expires_at" : { + "$ref" : "#/components/schemas/UploadExpiration" + }, + "upload_url" : { + "$ref" : "#/components/schemas/UploadUrl" } - }, - "ClientAppId" : { - "type" : "string", - "description" : "The ID of the client application", - "minLength" : 1, - "maxLength" : 19 - }, - "ClientAppUsage" : { - "type" : "object", - "description" : "Usage per client app", - "properties" : { - "client_app_id" : { - "type" : "string", - "description" : "The unique identifier for this project", - "format" : "^[0-9]{1,19}$" - }, - "usage" : { - "type" : "array", - "description" : "The usage value", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UsageFields" + } + }, + "ComplianceJobName" : { + "type" : "string", + "description" : "User-provided name for a compliance job.", + "maxLength" : 64, + "example" : "my-job" + }, + "ComplianceJobStatus" : { + "type" : "string", + "description" : "Status of a compliance job.", + "enum" : [ + "created", + "in_progress", + "failed", + "complete", + "expired" + ] + }, + "ComplianceJobType" : { + "type" : "string", + "description" : "Type of compliance job to list.", + "enum" : [ + "tweets", + "users" + ] + }, + "ConflictProblem" : { + "description" : "You cannot create a new job if one is already in progress.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "ConnectionExceptionProblem" : { + "description" : "A problem that indicates something is wrong with the connection.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "connection_issue" : { + "type" : "string", + "enum" : [ + "TooManyConnections", + "ProvisioningSubscription", + "RuleConfigurationIssue", + "RulesInvalidIssue" + ] } - }, - "usage_result_count" : { - "type" : "integer", - "description" : "The number of results returned", - "format" : "int32" } } - }, - "ClientDisconnectedProblem" : { - "description" : "Your client has gone away.", - "allOf" : [ - { + ] + }, + "ContextAnnotation" : { + "type" : "object", + "description" : "Annotation inferred from the Tweet text.", + "required" : [ + "domain", + "entity" + ], + "properties" : { + "domain" : { + "$ref" : "#/components/schemas/ContextAnnotationDomainFields" + }, + "entity" : { + "$ref" : "#/components/schemas/ContextAnnotationEntityFields" + } + } + }, + "ContextAnnotationDomainFields" : { + "type" : "object", + "description" : "Represents the data for the context annotation domain.", + "required" : [ + "id" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the context annotation domain." + }, + "id" : { + "type" : "string", + "description" : "The unique id for a context annotation domain.", + "pattern" : "^[0-9]{1,19}$" + }, + "name" : { + "type" : "string", + "description" : "Name of the context annotation domain." + } + } + }, + "ContextAnnotationEntityFields" : { + "type" : "object", + "description" : "Represents the data for the context annotation entity.", + "required" : [ + "id" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the context annotation entity." + }, + "id" : { + "type" : "string", + "description" : "The unique id for a context annotation entity.", + "pattern" : "^[0-9]{1,19}$" + }, + "name" : { + "type" : "string", + "description" : "Name of the context annotation entity." + } + } + }, + "CountryCode" : { + "type" : "string", + "description" : "A two-letter ISO 3166-1 alpha-2 country code.", + "pattern" : "^[A-Z]{2}$", + "example" : "US" + }, + "CreateAttachmentsMessageRequest" : { + "type" : "object", + "required" : [ + "attachments" + ], + "properties" : { + "attachments" : { + "$ref" : "#/components/schemas/DmAttachments" + }, + "text" : { + "type" : "string", + "description" : "Text of the message.", + "minLength" : 1 + } + } + }, + "CreateComplianceJobRequest" : { + "type" : "object", + "description" : "A request to create a new batch compliance job.", + "required" : [ + "type" + ], + "properties" : { + "name" : { + "$ref" : "#/components/schemas/ComplianceJobName" + }, + "resumable" : { + "type" : "boolean", + "description" : "If true, this endpoint will return a pre-signed URL with resumable uploads enabled." + }, + "type" : { + "type" : "string", + "description" : "Type of compliance job to list.", + "enum" : [ + "tweets", + "users" + ] + } + } + }, + "CreateComplianceJobResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/ComplianceJob" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" } - ] + } + } + }, + "CreateDmConversationRequest" : { + "type" : "object", + "required" : [ + "conversation_type", + "participant_ids", + "message" + ], + "properties" : { + "conversation_type" : { + "type" : "string", + "description" : "The conversation type that is being created.", + "enum" : [ + "Group" + ] + }, + "message" : { + "$ref" : "#/components/schemas/CreateMessageRequest" + }, + "participant_ids" : { + "$ref" : "#/components/schemas/DmParticipants" + } }, - "ClientForbiddenProblem" : { - "description" : "A problem that indicates your client is forbidden from making this request.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "properties" : { - "reason" : { - "type" : "string", - "enum" : [ - "official-client-forbidden", - "client-not-enrolled" - ] - }, - "registration_url" : { - "type" : "string", - "format" : "uri" - } + "additionalProperties" : false + }, + "CreateDmEventResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "dm_conversation_id", + "dm_event_id" + ], + "properties" : { + "dm_conversation_id" : { + "$ref" : "#/components/schemas/DmConversationId" + }, + "dm_event_id" : { + "$ref" : "#/components/schemas/DmEventId" } } - ] - }, - "ComplianceJob" : { - "type" : "object", - "required" : [ - "id", - "type", - "created_at", - "upload_url", - "download_url", - "upload_expires_at", - "download_expires_at", - "status" - ], - "properties" : { - "created_at" : { - "$ref" : "#/components/schemas/CreatedAt" - }, - "download_expires_at" : { - "$ref" : "#/components/schemas/DownloadExpiration" - }, - "download_url" : { - "$ref" : "#/components/schemas/DownloadUrl" - }, - "id" : { - "$ref" : "#/components/schemas/JobId" - }, - "name" : { - "$ref" : "#/components/schemas/ComplianceJobName" - }, - "status" : { - "$ref" : "#/components/schemas/ComplianceJobStatus" - }, - "type" : { - "$ref" : "#/components/schemas/ComplianceJobType" - }, - "upload_expires_at" : { - "$ref" : "#/components/schemas/UploadExpiration" - }, - "upload_url" : { - "$ref" : "#/components/schemas/UploadUrl" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "ComplianceJobName" : { - "type" : "string", - "description" : "User-provided name for a compliance job.", - "maxLength" : 64, - "example" : "my-job" - }, - "ComplianceJobStatus" : { - "type" : "string", - "description" : "Status of a compliance job.", - "enum" : [ - "created", - "in_progress", - "failed", - "complete", - "expired" - ] - }, - "ComplianceJobType" : { - "type" : "string", - "description" : "Type of compliance job to list.", - "enum" : [ - "tweets", - "users" - ] - }, - "ConflictProblem" : { - "description" : "You cannot create a new job if one is already in progress.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" + } + }, + "CreateMessageRequest" : { + "anyOf" : [ + { + "$ref" : "#/components/schemas/CreateTextMessageRequest" + }, + { + "$ref" : "#/components/schemas/CreateAttachmentsMessageRequest" + } + ] + }, + "CreateTextMessageRequest" : { + "type" : "object", + "required" : [ + "text" + ], + "properties" : { + "attachments" : { + "$ref" : "#/components/schemas/DmAttachments" + }, + "text" : { + "type" : "string", + "description" : "Text of the message.", + "minLength" : 1 + } + } + }, + "CreatedAt" : { + "type" : "string", + "description" : "Creation time of the compliance job.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "DeleteDmResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "deleted" : { + "type" : "boolean" + } } - ] - }, - "ConnectionExceptionProblem" : { - "description" : "A problem that indicates something is wrong with the connection.", - "allOf" : [ - { + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "properties" : { - "connection_issue" : { - "type" : "string", - "enum" : [ - "TooManyConnections", - "ProvisioningSubscription", - "RuleConfigurationIssue", - "RulesInvalidIssue" - ] - } - } - } - ] - }, - "ContextAnnotation" : { - "type" : "object", - "description" : "Annotation inferred from the Tweet text.", - "required" : [ - "domain", - "entity" - ], - "properties" : { - "domain" : { - "$ref" : "#/components/schemas/ContextAnnotationDomainFields" - }, - "entity" : { - "$ref" : "#/components/schemas/ContextAnnotationEntityFields" } } - }, - "ContextAnnotationDomainFields" : { - "type" : "object", - "description" : "Represents the data for the context annotation domain.", - "required" : [ - "id" - ], - "properties" : { - "description" : { - "type" : "string", - "description" : "Description of the context annotation domain." - }, - "id" : { - "type" : "string", - "description" : "The unique id for a context annotation domain.", - "pattern" : "^[0-9]{1,19}$" - }, - "name" : { - "type" : "string", - "description" : "Name of the context annotation domain." + } + }, + "DeleteRulesRequest" : { + "type" : "object", + "description" : "A response from deleting user-specified stream filtering rules.", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "type" : "object", + "description" : "IDs and values of all deleted user-specified stream filtering rules.", + "properties" : { + "ids" : { + "type" : "array", + "description" : "IDs of all deleted user-specified stream filtering rules.", + "items" : { + "$ref" : "#/components/schemas/RuleId" + } + }, + "values" : { + "type" : "array", + "description" : "Values of all deleted user-specified stream filtering rules.", + "items" : { + "$ref" : "#/components/schemas/RuleValue" + } + } } } - }, - "ContextAnnotationEntityFields" : { - "type" : "object", - "description" : "Represents the data for the context annotation entity.", - "required" : [ - "id" - ], - "properties" : { - "description" : { - "type" : "string", - "description" : "Description of the context annotation entity." - }, - "id" : { - "type" : "string", - "description" : "The unique id for a context annotation entity.", - "pattern" : "^[0-9]{1,19}$" - }, - "name" : { - "type" : "string", - "description" : "Name of the context annotation entity." + } + }, + "DisallowedResourceProblem" : { + "description" : "A problem that indicates that the resource requested violates the precepts of this API.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "resource_id", + "resource_type", + "section" + ], + "properties" : { + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] + } } } - }, - "CountryCode" : { - "type" : "string", - "description" : "A two-letter ISO 3166-1 alpha-2 country code.", - "pattern" : "^[A-Z]{2}$", - "example" : "US" - }, - "CreateAttachmentsMessageRequest" : { - "type" : "object", - "required" : [ - "attachments" - ], - "properties" : { - "attachments" : { - "$ref" : "#/components/schemas/DmAttachments" - }, - "text" : { - "type" : "string", - "description" : "Text of the message.", - "minLength" : 1 + ] + }, + "DmAttachments" : { + "type" : "array", + "description" : "Attachments to a DM Event.", + "items" : { + "$ref" : "#/components/schemas/DmMediaAttachment" + } + }, + "DmConversationId" : { + "type" : "string", + "description" : "Unique identifier of a DM conversation. This can either be a numeric string, or a pair of numeric strings separated by a '-' character in the case of one-on-one DM Conversations.", + "pattern" : "^([0-9]{1,19}-[0-9]{1,19}|[0-9]{15,19})$", + "example" : "123123123-456456456" + }, + "DmEvent" : { + "type" : "object", + "required" : [ + "id", + "event_type" + ], + "properties" : { + "attachments" : { + "type" : "object", + "description" : "Specifies the type of attachments (if any) present in this DM.", + "properties" : { + "card_ids" : { + "type" : "array", + "description" : "A list of card IDs (if cards are attached).", + "minItems" : 1, + "items" : { + "type" : "string" + } + }, + "media_keys" : { + "type" : "array", + "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MediaKey" + } + } } - } - }, - "CreateComplianceJobRequest" : { - "type" : "object", - "description" : "A request to create a new batch compliance job.", - "required" : [ - "type" - ], - "properties" : { - "name" : { - "$ref" : "#/components/schemas/ComplianceJobName" - }, - "resumable" : { - "type" : "boolean", - "description" : "If true, this endpoint will return a pre-signed URL with resumable uploads enabled." - }, - "type" : { - "type" : "string", - "description" : "Type of compliance job to list.", - "enum" : [ - "tweets", - "users" - ] + }, + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" } - } - }, - "CreateComplianceJobResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/ComplianceJob" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "created_at" : { + "type" : "string", + "format" : "date-time" + }, + "dm_conversation_id" : { + "$ref" : "#/components/schemas/DmConversationId" + }, + "event_type" : { + "type" : "string", + "example" : "MessageCreate" + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" } - } - }, - "CreateDmConversationRequest" : { - "type" : "object", - "required" : [ - "conversation_type", - "participant_ids", - "message" - ], - "properties" : { - "conversation_type" : { - "type" : "string", - "description" : "The conversation type that is being created.", - "enum" : [ - "Group" - ] - }, - "message" : { - "$ref" : "#/components/schemas/CreateMessageRequest" - }, - "participant_ids" : { - "$ref" : "#/components/schemas/DmParticipants" + }, + "id" : { + "$ref" : "#/components/schemas/DmEventId" + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" } }, - "additionalProperties" : false - }, - "CreateDmEventResponse" : { - "type" : "object", - "properties" : { - "data" : { + "participant_ids" : { + "type" : "array", + "description" : "A list of participants for a ParticipantsJoin or ParticipantsLeave event_type.", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "referenced_tweets" : { + "type" : "array", + "description" : "A list of Posts this DM refers to.", + "minItems" : 1, + "items" : { "type" : "object", "required" : [ - "dm_conversation_id", - "dm_event_id" + "id" ], "properties" : { - "dm_conversation_id" : { - "$ref" : "#/components/schemas/DmConversationId" - }, - "dm_event_id" : { - "$ref" : "#/components/schemas/DmEventId" + "id" : { + "$ref" : "#/components/schemas/TweetId" } } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "sender_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "text" : { + "type" : "string" + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntityDm" + } + } + } + }, + "DmEventId" : { + "type" : "string", + "description" : "Unique identifier of a DM Event.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "DmMediaAttachment" : { + "type" : "object", + "required" : [ + "media_id" + ], + "properties" : { + "media_id" : { + "$ref" : "#/components/schemas/MediaId" + } + } + }, + "DmParticipants" : { + "type" : "array", + "description" : "Participants for the DM Conversation.", + "minItems" : 2, + "maxItems" : 49, + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "DownloadExpiration" : { + "type" : "string", + "description" : "Expiration time of the download URL.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "DownloadUrl" : { + "type" : "string", + "description" : "URL from which the user will retrieve their compliance results.", + "format" : "uri" + }, + "DuplicateRuleProblem" : { + "description" : "The rule you have submitted is a duplicate.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "id" : { + "type" : "string" + }, + "value" : { + "type" : "string" } } } - }, - "CreateMessageRequest" : { - "anyOf" : [ - { - "$ref" : "#/components/schemas/CreateTextMessageRequest" - }, - { - "$ref" : "#/components/schemas/CreateAttachmentsMessageRequest" + ] + }, + "End" : { + "type" : "string", + "description" : "The end time of the bucket.", + "format" : "date-time" + }, + "EntityIndicesInclusiveExclusive" : { + "type" : "object", + "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is exclusive.", + "required" : [ + "start", + "end" + ], + "properties" : { + "end" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity ends. The index is exclusive.", + "minimum" : 0, + "example" : 61 + }, + "start" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", + "minimum" : 0, + "example" : 50 + } + } + }, + "EntityIndicesInclusiveInclusive" : { + "type" : "object", + "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is inclusive.", + "required" : [ + "start", + "end" + ], + "properties" : { + "end" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity ends. The index is inclusive.", + "minimum" : 0, + "example" : 61 + }, + "start" : { + "type" : "integer", + "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", + "minimum" : 0, + "example" : 50 + } + } + }, + "Error" : { + "type" : "object", + "required" : [ + "code", + "message" + ], + "properties" : { + "code" : { + "type" : "integer", + "format" : "int32" + }, + "message" : { + "type" : "string" + } + } + }, + "Expansions" : { + "type" : "object", + "properties" : { + "media" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Media" } - ] - }, - "CreateTextMessageRequest" : { - "type" : "object", - "required" : [ - "text" - ], - "properties" : { - "attachments" : { - "$ref" : "#/components/schemas/DmAttachments" - }, - "text" : { - "type" : "string", - "description" : "Text of the message.", - "minLength" : 1 + }, + "places" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Place" } - } - }, - "CreatedAt" : { - "type" : "string", - "description" : "Creation time of the compliance job.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "DeleteDmResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "deleted" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "polls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Poll" + } + }, + "topics" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Topic" + } + }, + "tweets" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "users" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" } } - }, - "DeleteRulesRequest" : { - "type" : "object", - "description" : "A response from deleting user-specified stream filtering rules.", - "required" : [ - "delete" - ], - "properties" : { - "delete" : { - "type" : "object", - "description" : "IDs and values of all deleted user-specified stream filtering rules.", - "properties" : { - "ids" : { - "type" : "array", - "description" : "IDs of all deleted user-specified stream filtering rules.", - "items" : { - "$ref" : "#/components/schemas/RuleId" - } - }, - "values" : { - "type" : "array", - "description" : "Values of all deleted user-specified stream filtering rules.", - "items" : { - "$ref" : "#/components/schemas/RuleValue" - } - } + } + }, + "FieldUnauthorizedProblem" : { + "description" : "A problem that indicates that you are not allowed to see a particular field on a Tweet, User, etc.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "resource_type", + "field", + "section" + ], + "properties" : { + "field" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] } } } - }, - "DisallowedResourceProblem" : { - "description" : "A problem that indicates that the resource requested violates the precepts of this API.", - "allOf" : [ - { + ] + }, + "FilteredStreamingTweetResponse" : { + "type" : "object", + "description" : "A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched.", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" - }, - { + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "matching_rules" : { + "type" : "array", + "description" : "The list of rules which matched the Tweet", + "items" : { "type" : "object", "required" : [ - "resource_id", - "resource_type", - "section" + "id" ], "properties" : { - "resource_id" : { - "type" : "string" - }, - "resource_type" : { - "type" : "string", - "enum" : [ - "user", - "tweet", - "media", - "list", - "space" - ] + "id" : { + "$ref" : "#/components/schemas/RuleId" }, - "section" : { - "type" : "string", - "enum" : [ - "data", - "includes" - ] + "tag" : { + "$ref" : "#/components/schemas/RuleTag" } } } - ] - }, - "DmAttachments" : { - "type" : "array", - "description" : "Attachments to a DM Event.", - "items" : { - "$ref" : "#/components/schemas/DmMediaAttachment" } - }, - "DmConversationId" : { - "type" : "string", - "description" : "Unique identifier of a DM conversation. This can either be a numeric string, or a pair of numeric strings separated by a '-' character in the case of one-on-one DM Conversations.", - "pattern" : "^([0-9]{1,19}-[0-9]{1,19}|[0-9]{15,19})$", - "example" : "123123123-456456456" - }, - "DmEvent" : { - "type" : "object", - "required" : [ - "id", - "event_type" - ], - "properties" : { - "attachments" : { - "type" : "object", - "description" : "Specifies the type of attachments (if any) present in this DM.", - "properties" : { - "card_ids" : { - "type" : "array", - "description" : "A list of card IDs (if cards are attached).", - "minItems" : 1, - "items" : { - "type" : "string" - } + } + }, + "FullTextEntities" : { + "type" : "object", + "properties" : { + "annotations" : { + "type" : "array", + "minItems" : 1, + "items" : { + "description" : "Annotation for entities based on the Tweet text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveInclusive" }, - "media_keys" : { - "type" : "array", - "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/MediaKey" - } - } - } - }, - "cashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/CashtagEntity" - } - }, - "created_at" : { - "type" : "string", - "format" : "date-time" - }, - "dm_conversation_id" : { - "$ref" : "#/components/schemas/DmConversationId" - }, - "event_type" : { - "type" : "string", - "example" : "MessageCreate" - }, - "hashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/HashtagEntity" - } - }, - "id" : { - "$ref" : "#/components/schemas/DmEventId" - }, - "mentions" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/MentionEntity" - } - }, - "participant_ids" : { - "type" : "array", - "description" : "A list of participants for a ParticipantsJoin or ParticipantsLeave event_type.", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "referenced_tweets" : { - "type" : "array", - "description" : "A list of Posts this DM refers to.", - "minItems" : 1, - "items" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/TweetId" + { + "type" : "object", + "description" : "Represents the data for the annotation.", + "properties" : { + "normalized_text" : { + "type" : "string", + "description" : "Text used to determine annotation.", + "example" : "Barack Obama" + }, + "probability" : { + "type" : "number", + "description" : "Confidence factor for annotation type.", + "minimum" : 0, + "maximum" : 1, + "format" : "double" + }, + "type" : { + "type" : "string", + "description" : "Annotation type.", + "example" : "Person" + } } } - } - }, - "sender_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "text" : { - "type" : "string" - }, - "urls" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UrlEntityDm" - } + ] } - } - }, - "DmEventId" : { - "type" : "string", - "description" : "Unique identifier of a DM Event.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1146654567674912769" - }, - "DmMediaAttachment" : { - "type" : "object", - "required" : [ - "media_id" - ], - "properties" : { - "media_id" : { - "$ref" : "#/components/schemas/MediaId" + }, + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" + } + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" + } + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" + } + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" } } - }, - "DmParticipants" : { - "type" : "array", - "description" : "Participants for the DM Conversation.", - "minItems" : 2, - "maxItems" : 49, - "items" : { - "$ref" : "#/components/schemas/UserId" + } + }, + "GenericProblem" : { + "description" : "A generic problem with no additional information beyond that provided by the HTTP status code.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" } - }, - "DownloadExpiration" : { - "type" : "string", - "description" : "Expiration time of the download URL.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "DownloadUrl" : { - "type" : "string", - "description" : "URL from which the user will retrieve their compliance results.", - "format" : "uri" - }, - "DuplicateRuleProblem" : { - "description" : "The rule you have submitted is a duplicate.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" + ] + }, + "Geo" : { + "type" : "object", + "required" : [ + "type", + "bbox", + "properties" + ], + "properties" : { + "bbox" : { + "type" : "array", + "minItems" : 4, + "maxItems" : 4, + "items" : { + "type" : "number", + "minimum" : -180, + "maximum" : 180, + "format" : "double" }, - { - "type" : "object", - "properties" : { - "id" : { - "type" : "string" - }, - "value" : { - "type" : "string" - } - } - } - ] - }, - "End" : { - "type" : "string", - "description" : "The end time of the bucket.", - "format" : "date-time" - }, - "EntityIndicesInclusiveExclusive" : { - "type" : "object", - "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is exclusive.", - "required" : [ - "start", - "end" - ], + "example" : [ + -105.193475, + 39.60973, + -105.053164, + 39.761974 + ] + }, + "geometry" : { + "$ref" : "#/components/schemas/Point" + }, "properties" : { - "end" : { - "type" : "integer", - "description" : "Index (zero-based) at which position this entity ends. The index is exclusive.", - "minimum" : 0, - "example" : 61 - }, - "start" : { - "type" : "integer", - "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", - "minimum" : 0, - "example" : 50 - } + "type" : "object" + }, + "type" : { + "type" : "string", + "enum" : [ + "Feature" + ] } - }, - "EntityIndicesInclusiveInclusive" : { - "type" : "object", - "description" : "Represent a boundary range (start and end index) for a recognized entity (for example a hashtag or a mention). `start` must be smaller than `end`. The start index is inclusive, the end index is inclusive.", - "required" : [ - "start", - "end" - ], - "properties" : { - "end" : { - "type" : "integer", - "description" : "Index (zero-based) at which position this entity ends. The index is inclusive.", - "minimum" : 0, - "example" : 61 - }, - "start" : { - "type" : "integer", - "description" : "Index (zero-based) at which position this entity starts. The index is inclusive.", - "minimum" : 0, - "example" : 50 + } + }, + "Get2ComplianceJobsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/ComplianceJob" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Error" : { - "type" : "object", - "required" : [ - "code", - "message" - ], - "properties" : { - "code" : { - "type" : "integer", - "format" : "int32" - }, - "message" : { - "type" : "string" + } + }, + "Get2ComplianceJobsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ComplianceJob" } - } - }, - "Expansions" : { - "type" : "object", - "properties" : { - "media" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Media" - } - }, - "places" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Place" - } - }, - "polls" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Poll" - } - }, - "topics" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Topic" - } - }, - "tweets" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "users" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "FieldUnauthorizedProblem" : { - "description" : "A problem that indicates that you are not allowed to see a particular field on a Tweet, User, etc.", - "allOf" : [ - { + } + }, + "Get2DmConversationsIdDmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "required" : [ - "resource_type", - "field", - "section" - ], - "properties" : { - "field" : { - "type" : "string" - }, - "resource_type" : { - "type" : "string", - "enum" : [ - "user", - "tweet", - "media", - "list", - "space" - ] - }, - "section" : { - "type" : "string", - "enum" : [ - "data", - "includes" - ] - } - } } - ] - }, - "FilteredStreamingTweetResponse" : { - "type" : "object", - "description" : "A Tweet or error that can be returned by the streaming Tweet API. The values returned with a successful streamed Tweet includes the user provided rules that the Tweet matched.", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "matching_rules" : { - "type" : "array", - "description" : "The list of rules which matched the Tweet", - "items" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/RuleId" - }, - "tag" : { - "$ref" : "#/components/schemas/RuleTag" - } - } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "FullTextEntities" : { - "type" : "object", - "properties" : { - "annotations" : { - "type" : "array", - "minItems" : 1, - "items" : { - "description" : "Annotation for entities based on the Tweet text.", - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveInclusive" - }, - { - "type" : "object", - "description" : "Represents the data for the annotation.", - "properties" : { - "normalized_text" : { - "type" : "string", - "description" : "Text used to determine annotation.", - "example" : "Barack Obama" - }, - "probability" : { - "type" : "number", - "description" : "Confidence factor for annotation type.", - "minimum" : 0, - "maximum" : 1, - "format" : "double" - }, - "type" : { - "type" : "string", - "description" : "Annotation type.", - "example" : "Person" - } - } - } - ] - } - }, - "cashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/CashtagEntity" - } - }, - "hashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/HashtagEntity" - } - }, - "mentions" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/MentionEntity" - } - }, - "urls" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UrlEntity" - } + } + }, + "Get2DmConversationsWithParticipantIdDmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" } - } - }, - "GenericProblem" : { - "description" : "A generic problem with no additional information beyond that provided by the HTTP status code.", - "allOf" : [ - { + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" } - ] - }, - "Geo" : { - "type" : "object", - "required" : [ - "type", - "bbox", - "properties" - ], - "properties" : { - "bbox" : { - "type" : "array", - "minItems" : 4, - "maxItems" : 4, - "items" : { - "type" : "number", - "minimum" : -180, - "maximum" : 180, - "format" : "double" - }, - "example" : [ - -105.193475, - 39.60973, - -105.053164, - 39.761974 - ] - }, - "geometry" : { - "$ref" : "#/components/schemas/Point" - }, + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", "properties" : { - "type" : "object" - }, - "type" : { - "type" : "string", - "enum" : [ - "Feature" - ] - } - } - }, - "Get2ComplianceJobsIdResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/ComplianceJob" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2ComplianceJobsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/ComplianceJob" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "meta" : { - "type" : "object", - "properties" : { - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2DmEventsEventIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/DmEvent" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2DmConversationsIdDmEventsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/DmEvent" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2DmEventsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/DmEvent" } - } - }, - "Get2DmConversationsWithParticipantIdDmEventsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/DmEvent" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - } - }, - "Get2DmEventsEventIdResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/DmEvent" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2DmEventsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/DmEvent" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2LikesFirehoseStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2LikesFirehoseStreamResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Like" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2LikesSample10StreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2LikesSample10StreamResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Like" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2ListsIdFollowersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2ListsIdFollowersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2ListsIdMembersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2ListsIdMembersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2ListsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/List" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2ListsIdResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/List" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2ListsIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" } - } - }, - "Get2ListsIdTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2SpacesByCreatorIdsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Space" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2SpacesByCreatorIdsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2SpacesIdBuyersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2SpacesIdBuyersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2SpacesIdResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Space" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2SpacesIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Space" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2SpacesIdTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2SpacesIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2SpacesResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Space" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2SpacesResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2SpacesSearchResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Space" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2SpacesSearchResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Space" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2TrendsByWoeidWoeidResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Trend" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "Get2TrendsByWoeidWoeidResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Trend" } - } - }, - "Get2TweetsCountsAllResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/SearchCount" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "total_tweet_count" : { - "$ref" : "#/components/schemas/Aggregate" - } - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Get2TweetsCountsRecentResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/SearchCount" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "total_tweet_count" : { - "$ref" : "#/components/schemas/Aggregate" - } + } + }, + "Get2TweetsCountsAllResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/SearchCount" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "total_tweet_count" : { + "$ref" : "#/components/schemas/Aggregate" } } } - }, - "Get2TweetsFirehoseStreamLangEnResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2TweetsCountsRecentResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/SearchCount" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "total_tweet_count" : { + "$ref" : "#/components/schemas/Aggregate" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2TweetsFirehoseStreamLangJaResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2TweetsFirehoseStreamLangEnResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsFirehoseStreamLangKoResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2TweetsFirehoseStreamLangJaResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsFirehoseStreamLangPtResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2TweetsFirehoseStreamLangKoResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsFirehoseStreamResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2TweetsFirehoseStreamLangPtResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsIdLikingUsersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsFirehoseStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsIdQuoteTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2TweetsIdLikingUsersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2TweetsIdResponse" : { - "type" : "object", - "properties" : { - "data" : { + } + }, + "Get2TweetsIdQuoteTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2TweetsIdRetweetedByResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsIdRetweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsIdRetweetedByResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" } - } - }, - "Get2TweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2TweetsSample10StreamResponse" : { - "type" : "object", - "properties" : { - "data" : { + } + }, + "Get2TweetsIdRetweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2TweetsSampleStreamResponse" : { - "type" : "object", - "properties" : { - "data" : { + } + }, + "Get2TweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsSearchAllResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsSample10StreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsSearchRecentResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsSampleStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2TweetsSearchStreamResponse" : { - "type" : "object", - "properties" : { - "data" : { + } + }, + "Get2TweetsSearchAllResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } - } - }, - "Get2TweetsSearchStreamRulesCountsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/RulesCount" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - } - }, - "Get2UsageTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Usage" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersByResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2TweetsSearchRecentResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2UsersByUsernameUsernameResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/User" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + } + }, + "Get2TweetsSearchStreamResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2UsersIdBlockingResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2TweetsSearchStreamRulesCountsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/RulesCount" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Get2UsersIdBookmarksResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2UsageTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Usage" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Get2UsersIdFollowedListsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/List" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2UsersByResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2UsersIdFollowersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2UsersByUsernameUsernameResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "Get2UsersIdFollowingResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdBlockingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdLikedTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdBookmarksResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdListMembershipsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/List" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdFollowedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdMentionsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdFollowersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdMutingResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + } + }, + "Get2UsersIdFollowingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" } - } - }, - "Get2UsersIdOwnedListsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/List" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - } - }, - "Get2UsersIdPinnedListsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/List" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/User" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2UsersIdLikedTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Get2UsersIdTimelinesReverseChronologicalResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdListMembershipsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersIdTweetsResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Tweet" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "newest_id" : { - "$ref" : "#/components/schemas/NewestId" - }, - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "oldest_id" : { - "$ref" : "#/components/schemas/OldestId" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - }, - "result_count" : { - "$ref" : "#/components/schemas/ResultCount" - } + } + }, + "Get2UsersIdMentionsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "Get2UsersMeResponse" : { - "type" : "object", - "properties" : { - "data" : { + } + }, + "Get2UsersIdMutingResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/User" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } - } - }, - "Get2UsersResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - } - }, - "Get2UsersSearchResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/User" - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" - }, - "meta" : { - "type" : "object", - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "previous_token" : { - "$ref" : "#/components/schemas/PreviousToken" - } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "HashtagEntity" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" - }, - { - "$ref" : "#/components/schemas/HashtagFields" - } - ] - }, - "HashtagFields" : { - "type" : "object", - "description" : "Represent the portion of text recognized as a Hashtag, and its start and end position within the text.", - "required" : [ - "tag" - ], - "properties" : { - "tag" : { - "type" : "string", - "description" : "The text of the Hashtag.", - "example" : "MondayMotivation" + } + }, + "Get2UsersIdOwnedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" } - } - }, - "HttpStatusCode" : { - "type" : "integer", - "description" : "HTTP Status Code.", - "minimum" : 100, - "maximum" : 599 - }, - "InvalidRequestProblem" : { - "description" : "A problem that indicates this request is invalid.", - "allOf" : [ - { + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "properties" : { - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "type" : "object", - "properties" : { - "message" : { - "type" : "string" - }, - "parameters" : { - "type" : "object", - "additionalProperties" : { - "type" : "array", - "items" : { - "type" : "string" - } - } - } - } - } - } - } } - ] - }, - "InvalidRuleProblem" : { - "description" : "The rule you have submitted is invalid.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - } - ] - }, - "JobId" : { - "type" : "string", - "description" : "Compliance Job ID.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1372966999991541762" - }, - "Like" : { - "type" : "object", - "description" : "A Like event, with the liking user and the tweet being liked", - "properties" : { - "created_at" : { - "type" : "string", - "description" : "Creation time of the Tweet.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "id" : { - "$ref" : "#/components/schemas/LikeId" - }, - "liked_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "liking_user_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "timestamp_ms" : { - "type" : "integer", - "description" : "Timestamp in milliseconds of creation.", - "format" : "int32" + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } } } - }, - "LikeComplianceSchema" : { - "type" : "object", - "required" : [ - "delete" - ], - "properties" : { - "delete" : { - "$ref" : "#/components/schemas/UnlikeComplianceSchema" + } + }, + "Get2UsersIdPinnedListsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/List" } - } - }, - "LikeId" : { - "type" : "string", - "description" : "The unique identifier of this Like.", - "pattern" : "^[A-Za-z0-9_]{1,40}$", - "example" : "8ba4f34e6235d905a46bac021d98e923" - }, - "LikesComplianceStreamResponse" : { - "description" : "Likes compliance stream events.", - "oneOf" : [ - { - "type" : "object", - "description" : "Compliance event.", - "required" : [ - "data" - ], - "properties" : { - "data" : { - "$ref" : "#/components/schemas/LikeComplianceSchema" - } - } - }, - { - "type" : "object", - "required" : [ - "errors" - ], - "properties" : { - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - } - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - ] - }, - "List" : { - "type" : "object", - "description" : "A X List is a curated group of accounts.", - "required" : [ - "id", - "name" - ], - "properties" : { - "created_at" : { - "type" : "string", - "format" : "date-time" - }, - "description" : { - "type" : "string" - }, - "follower_count" : { - "type" : "integer" - }, - "id" : { - "$ref" : "#/components/schemas/ListId" - }, - "member_count" : { - "type" : "integer" - }, - "name" : { - "type" : "string", - "description" : "The name of this List." - }, - "owner_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "private" : { - "type" : "boolean" + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" + } } } - }, - "ListAddUserRequest" : { - "type" : "object", - "required" : [ - "user_id" - ], - "properties" : { - "user_id" : { - "$ref" : "#/components/schemas/UserId" + } + }, + "Get2UsersIdResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "ListCreateRequest" : { - "type" : "object", - "required" : [ - "name" - ], - "properties" : { - "description" : { - "type" : "string", - "minLength" : 0, - "maxLength" : 100 - }, - "name" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 25 - }, - "private" : { - "type" : "boolean", - "default" : false + } + }, + "Get2UsersIdTimelinesReverseChronologicalResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" } - } - }, - "ListCreateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "description" : "A X List is a curated group of accounts.", - "required" : [ - "id", - "name" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/ListId" - }, - "name" : { - "type" : "string", - "description" : "The name of this List." - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "ListDeleteResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "deleted" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2UsersIdTweetsResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Tweet" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "newest_id" : { + "$ref" : "#/components/schemas/NewestId" + }, + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "oldest_id" : { + "$ref" : "#/components/schemas/OldestId" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" + }, + "result_count" : { + "$ref" : "#/components/schemas/ResultCount" } } } - }, - "ListFollowedRequest" : { - "type" : "object", - "required" : [ - "list_id" - ], - "properties" : { - "list_id" : { - "$ref" : "#/components/schemas/ListId" + } + }, + "Get2UsersMeResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "ListFollowedResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "following" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + } + }, + "Get2UsersResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" } - }, - "ListId" : { - "type" : "string", - "description" : "The unique identifier of this List.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1146654567674912769" - }, - "ListMutateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "is_member" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "Get2UsersSearchResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/User" + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + }, + "meta" : { + "type" : "object", + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "previous_token" : { + "$ref" : "#/components/schemas/PreviousToken" } } } - }, - "ListPinnedRequest" : { - "type" : "object", - "required" : [ - "list_id" - ], - "properties" : { - "list_id" : { - "$ref" : "#/components/schemas/ListId" - } + } + }, + "HashtagEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/HashtagFields" } - }, - "ListPinnedResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "pinned" : { - "type" : "boolean" + ] + }, + "HashtagFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a Hashtag, and its start and end position within the text.", + "required" : [ + "tag" + ], + "properties" : { + "tag" : { + "type" : "string", + "description" : "The text of the Hashtag.", + "example" : "MondayMotivation" + } + } + }, + "HttpStatusCode" : { + "type" : "integer", + "description" : "HTTP Status Code.", + "minimum" : 100, + "maximum" : 599 + }, + "InvalidRequestProblem" : { + "description" : "A problem that indicates this request is invalid.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "type" : "object", + "properties" : { + "message" : { + "type" : "string" + }, + "parameters" : { + "type" : "object", + "additionalProperties" : { + "type" : "array", + "items" : { + "type" : "string" + } + } + } + } } } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } } } - }, - "ListUnpinResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "pinned" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - } + ] + }, + "InvalidRuleProblem" : { + "description" : "The rule you have submitted is invalid.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" } - }, - "ListUpdateRequest" : { - "type" : "object", - "properties" : { - "description" : { - "type" : "string", - "minLength" : 0, - "maxLength" : 100 - }, - "name" : { - "type" : "string", - "minLength" : 1, - "maxLength" : 25 - }, - "private" : { - "type" : "boolean" - } + ] + }, + "JobId" : { + "type" : "string", + "description" : "Compliance Job ID.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1372966999991541762" + }, + "Like" : { + "type" : "object", + "description" : "A Like event, with the liking user and the tweet being liked", + "properties" : { + "created_at" : { + "type" : "string", + "description" : "Creation time of the Tweet.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "id" : { + "$ref" : "#/components/schemas/LikeId" + }, + "liked_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "liking_user_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "timestamp_ms" : { + "type" : "integer", + "description" : "Timestamp in milliseconds of creation.", + "format" : "int32" } - }, - "ListUpdateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "updated" : { - "type" : "boolean" - } + } + }, + "LikeComplianceSchema" : { + "type" : "object", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "$ref" : "#/components/schemas/UnlikeComplianceSchema" + } + } + }, + "LikeId" : { + "type" : "string", + "description" : "The unique identifier of this Like.", + "pattern" : "^[A-Za-z0-9_]{1,40}$", + "example" : "8ba4f34e6235d905a46bac021d98e923" + }, + "LikesComplianceStreamResponse" : { + "description" : "Likes compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/LikeComplianceSchema" } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } } } } - }, - "Media" : { - "type" : "object", - "required" : [ - "type" - ], - "properties" : { - "height" : { - "$ref" : "#/components/schemas/MediaHeight" - }, - "media_key" : { - "$ref" : "#/components/schemas/MediaKey" - }, - "type" : { - "type" : "string" - }, - "width" : { - "$ref" : "#/components/schemas/MediaWidth" + ] + }, + "List" : { + "type" : "object", + "description" : "A X List is a curated group of accounts.", + "required" : [ + "id", + "name" + ], + "properties" : { + "created_at" : { + "type" : "string", + "format" : "date-time" + }, + "description" : { + "type" : "string" + }, + "follower_count" : { + "type" : "integer" + }, + "id" : { + "$ref" : "#/components/schemas/ListId" + }, + "member_count" : { + "type" : "integer" + }, + "name" : { + "type" : "string", + "description" : "The name of this List." + }, + "owner_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "private" : { + "type" : "boolean" + } + } + }, + "ListAddUserRequest" : { + "type" : "object", + "required" : [ + "user_id" + ], + "properties" : { + "user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "ListCreateRequest" : { + "type" : "object", + "required" : [ + "name" + ], + "properties" : { + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + }, + "name" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 25 + }, + "private" : { + "type" : "boolean", + "default" : false + } + } + }, + "ListCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "description" : "A X List is a curated group of accounts.", + "required" : [ + "id", + "name" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/ListId" + }, + "name" : { + "type" : "string", + "description" : "The name of this List." + } } }, - "discriminator" : { - "propertyName" : "type", - "mapping" : { - "animated_gif" : "#/components/schemas/AnimatedGif", - "photo" : "#/components/schemas/Photo", - "video" : "#/components/schemas/Video" + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "MediaHeight" : { - "type" : "integer", - "description" : "The height of the media in pixels.", - "minimum" : 0 - }, - "MediaId" : { - "type" : "string", - "description" : "The unique identifier of this Media.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1146654567674912769" - }, - "MediaKey" : { - "type" : "string", - "description" : "The Media Key identifier for this attachment.", - "pattern" : "^([0-9]+)_([0-9]+)$" - }, - "MediaWidth" : { - "type" : "integer", - "description" : "The width of the media in pixels.", - "minimum" : 0 - }, - "MentionEntity" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" - }, - { - "$ref" : "#/components/schemas/MentionFields" + } + }, + "ListDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "deleted" : { + "type" : "boolean" + } } - ] - }, - "MentionFields" : { - "type" : "object", - "description" : "Represent the portion of text recognized as a User mention, and its start and end position within the text.", - "required" : [ - "username" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/UserId" - }, - "username" : { - "$ref" : "#/components/schemas/UserName" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "MuteUserMutationResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "muting" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "ListFollowedRequest" : { + "type" : "object", + "required" : [ + "list_id" + ], + "properties" : { + "list_id" : { + "$ref" : "#/components/schemas/ListId" + } + } + }, + "ListFollowedResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" } } - } - }, - "MuteUserRequest" : { - "type" : "object", - "required" : [ - "target_user_id" - ], - "properties" : { - "target_user_id" : { - "$ref" : "#/components/schemas/UserId" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "NewestId" : { - "type" : "string", - "description" : "The newest id in this response." - }, - "NextToken" : { - "type" : "string", - "description" : "The next token.", - "minLength" : 1 - }, - "NonCompliantRulesProblem" : { - "description" : "A problem that indicates the user's rule set is not compliant.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" + } + }, + "ListId" : { + "type" : "string", + "description" : "The unique identifier of this List.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "ListMutateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "is_member" : { + "type" : "boolean" + } } - ] - }, - "NoteTweetText" : { - "type" : "string", - "description" : "The note content of the Tweet.", - "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" - }, - "Oauth1PermissionsProblem" : { - "description" : "A problem that indicates your client application does not have the required OAuth1 permissions for the requested endpoint.", - "allOf" : [ - { + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/Problem" } - ] - }, - "OldestId" : { - "type" : "string", - "description" : "The oldest id in this response." - }, - "OperationalDisconnectProblem" : { - "description" : "You have been disconnected for operational reasons.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "properties" : { - "disconnect_type" : { - "type" : "string", - "enum" : [ - "OperationalDisconnect", - "UpstreamOperationalDisconnect", - "ForceDisconnect", - "UpstreamUncleanDisconnect", - "SlowReader", - "InternalError", - "ClientApplicationStateDegraded", - "InvalidRules" - ] - } + } + } + }, + "ListPinnedRequest" : { + "type" : "object", + "required" : [ + "list_id" + ], + "properties" : { + "list_id" : { + "$ref" : "#/components/schemas/ListId" + } + } + }, + "ListPinnedResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "pinned" : { + "type" : "boolean" } } - ] - }, - "PaginationToken32" : { - "type" : "string", - "description" : "A base32 pagination token.", - "minLength" : 16 - }, - "PaginationToken36" : { - "type" : "string", - "description" : "A base36 pagination token.", - "minLength" : 1 - }, - "PaginationTokenLong" : { - "type" : "string", - "description" : "A 'long' pagination token.", - "minLength" : 1, - "maxLength" : 19 - }, - "Photo" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/Media" - }, - { - "type" : "object", - "properties" : { - "alt_text" : { - "type" : "string" - }, - "url" : { - "type" : "string", - "format" : "uri" - } - } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - ] - }, - "Place" : { - "type" : "object", - "required" : [ - "id", - "full_name" - ], - "properties" : { - "contained_within" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/PlaceId" + } + } + }, + "ListUnpinResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "pinned" : { + "type" : "boolean" } - }, - "country" : { - "type" : "string", - "description" : "The full name of the county in which this place exists.", - "example" : "United States" - }, - "country_code" : { - "$ref" : "#/components/schemas/CountryCode" - }, - "full_name" : { - "type" : "string", - "description" : "The full name of this place.", - "example" : "Lakewood, CO" - }, - "geo" : { - "$ref" : "#/components/schemas/Geo" - }, - "id" : { - "$ref" : "#/components/schemas/PlaceId" - }, - "name" : { - "type" : "string", - "description" : "The human readable name of this place.", - "example" : "Lakewood" - }, - "place_type" : { - "$ref" : "#/components/schemas/PlaceType" } - } - }, - "PlaceId" : { - "type" : "string", - "description" : "The identifier for this place.", - "example" : "f7eb2fa2fea288b1" - }, - "PlaceType" : { - "type" : "string", - "enum" : [ - "poi", - "neighborhood", - "city", - "admin", - "country", - "unknown" - ], - "example" : "city" - }, - "Point" : { - "type" : "object", - "description" : "A [GeoJson Point](https://tools.ietf.org/html/rfc7946#section-3.1.2) geometry object.", - "required" : [ - "type", - "coordinates" - ], - "properties" : { - "coordinates" : { - "$ref" : "#/components/schemas/Position" - }, - "type" : { - "type" : "string", - "enum" : [ - "Point" - ], - "example" : "Point" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Poll" : { - "type" : "object", - "description" : "Represent a Poll attached to a Tweet.", - "required" : [ - "id", - "options" - ], - "properties" : { - "duration_minutes" : { - "type" : "integer", - "minimum" : 5, - "maximum" : 10080, - "format" : "int32" - }, - "end_datetime" : { - "type" : "string", - "format" : "date-time" - }, - "id" : { - "$ref" : "#/components/schemas/PollId" - }, - "options" : { - "type" : "array", - "minItems" : 2, - "maxItems" : 4, - "items" : { - "$ref" : "#/components/schemas/PollOption" + } + }, + "ListUpdateRequest" : { + "type" : "object", + "properties" : { + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + }, + "name" : { + "type" : "string", + "minLength" : 1, + "maxLength" : 25 + }, + "private" : { + "type" : "boolean" + } + } + }, + "ListUpdateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "updated" : { + "type" : "boolean" } - }, - "voting_status" : { - "type" : "string", - "enum" : [ - "open", - "closed" - ] } - } - }, - "PollId" : { - "type" : "string", - "description" : "Unique identifier of this poll.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1365059861688410112" - }, - "PollOption" : { - "type" : "object", - "description" : "Describes a choice in a Poll object.", - "required" : [ - "position", - "label", - "votes" - ], - "properties" : { - "label" : { - "$ref" : "#/components/schemas/PollOptionLabel" - }, - "position" : { - "type" : "integer", - "description" : "Position of this choice in the poll." - }, - "votes" : { - "type" : "integer", - "description" : "Number of users who voted for this choice." + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "PollOptionLabel" : { - "type" : "string", - "description" : "The text of a poll choice.", - "minLength" : 1, - "maxLength" : 25 - }, - "Position" : { - "type" : "array", - "description" : "A [GeoJson Position](https://tools.ietf.org/html/rfc7946#section-3.1.1) in the format `[longitude,latitude]`.", - "minItems" : 2, - "maxItems" : 2, - "items" : { - "type" : "number" + } + }, + "Media" : { + "type" : "object", + "required" : [ + "type" + ], + "properties" : { + "height" : { + "$ref" : "#/components/schemas/MediaHeight" }, - "example" : [ - -105.18816086351444, - 40.247749999999996 - ] - }, - "PreviousToken" : { - "type" : "string", - "description" : "The previous token.", - "minLength" : 1 - }, - "Problem" : { - "type" : "object", - "description" : "An HTTP Problem Details object, as defined in IETF RFC 7807 (https://tools.ietf.org/html/rfc7807).", - "required" : [ - "type", - "title" - ], - "properties" : { - "detail" : { - "type" : "string" - }, - "status" : { - "type" : "integer" - }, - "title" : { - "type" : "string" - }, - "type" : { - "type" : "string" - } + "media_key" : { + "$ref" : "#/components/schemas/MediaKey" }, - "discriminator" : { - "propertyName" : "type", - "mapping" : { - "about:blank" : "#/components/schemas/GenericProblem", - "https://api.twitter.com/2/problems/client-disconnected" : "#/components/schemas/ClientDisconnectedProblem", - "https://api.twitter.com/2/problems/client-forbidden" : "#/components/schemas/ClientForbiddenProblem", - "https://api.twitter.com/2/problems/conflict" : "#/components/schemas/ConflictProblem", - "https://api.twitter.com/2/problems/disallowed-resource" : "#/components/schemas/DisallowedResourceProblem", - "https://api.twitter.com/2/problems/duplicate-rules" : "#/components/schemas/DuplicateRuleProblem", - "https://api.twitter.com/2/problems/invalid-request" : "#/components/schemas/InvalidRequestProblem", - "https://api.twitter.com/2/problems/invalid-rules" : "#/components/schemas/InvalidRuleProblem", - "https://api.twitter.com/2/problems/noncompliant-rules" : "#/components/schemas/NonCompliantRulesProblem", - "https://api.twitter.com/2/problems/not-authorized-for-field" : "#/components/schemas/FieldUnauthorizedProblem", - "https://api.twitter.com/2/problems/not-authorized-for-resource" : "#/components/schemas/ResourceUnauthorizedProblem", - "https://api.twitter.com/2/problems/oauth1-permissions" : "#/components/schemas/Oauth1PermissionsProblem", - "https://api.twitter.com/2/problems/operational-disconnect" : "#/components/schemas/OperationalDisconnectProblem", - "https://api.twitter.com/2/problems/resource-not-found" : "#/components/schemas/ResourceNotFoundProblem", - "https://api.twitter.com/2/problems/resource-unavailable" : "#/components/schemas/ResourceUnavailableProblem", - "https://api.twitter.com/2/problems/rule-cap" : "#/components/schemas/RulesCapProblem", - "https://api.twitter.com/2/problems/streaming-connection" : "#/components/schemas/ConnectionExceptionProblem", - "https://api.twitter.com/2/problems/unsupported-authentication" : "#/components/schemas/UnsupportedAuthenticationProblem", - "https://api.twitter.com/2/problems/usage-capped" : "#/components/schemas/UsageCapExceededProblem" - } - } - }, - "ReplySettings" : { - "type" : "string", - "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, and following.", - "pattern" : "^[A-Za-z]{1,12}$", - "enum" : [ - "everyone", - "mentionedUsers", - "following", - "other" - ] - }, - "ReplySettingsWithVerifiedUsers" : { - "type" : "string", - "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, subscribers, verified and following.", - "pattern" : "^[A-Za-z]{1,12}$", - "enum" : [ - "everyone", - "mentionedUsers", - "following", - "other", - "subscribers", - "verified" - ] - }, - "ResourceNotFoundProblem" : { - "description" : "A problem that indicates that a given Tweet, User, etc. does not exist.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "required" : [ - "parameter", - "value", - "resource_id", - "resource_type" - ], - "properties" : { - "parameter" : { - "type" : "string", - "minLength" : 1 - }, - "resource_id" : { - "type" : "string" - }, - "resource_type" : { - "type" : "string", - "enum" : [ - "user", - "tweet", - "media", - "list", - "space" - ] - }, - "value" : { - "type" : "string", - "description" : "Value will match the schema of the field." - } - } - } - ] - }, - "ResourceUnauthorizedProblem" : { - "description" : "A problem that indicates you are not allowed to see a particular Tweet, User, etc.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "required" : [ - "value", - "resource_id", - "resource_type", - "section", - "parameter" - ], - "properties" : { - "parameter" : { - "type" : "string" - }, - "resource_id" : { - "type" : "string" - }, - "resource_type" : { - "type" : "string", - "enum" : [ - "user", - "tweet", - "media", - "list", - "space" - ] - }, - "section" : { - "type" : "string", - "enum" : [ - "data", - "includes" - ] - }, - "value" : { - "type" : "string" - } - } - } - ] - }, - "ResourceUnavailableProblem" : { - "description" : "A problem that indicates a particular Tweet, User, etc. is not available to you.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "required" : [ - "parameter", - "resource_id", - "resource_type" - ], - "properties" : { - "parameter" : { - "type" : "string", - "minLength" : 1 - }, - "resource_id" : { - "type" : "string" - }, - "resource_type" : { - "type" : "string", - "enum" : [ - "user", - "tweet", - "media", - "list", - "space" - ] - } - } - } - ] - }, - "ResultCount" : { - "type" : "integer", - "description" : "The number of results returned in this response.", - "format" : "int32" - }, - "Rule" : { - "type" : "object", - "description" : "A user-provided stream filtering rule.", - "required" : [ - "value" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/RuleId" - }, - "tag" : { - "$ref" : "#/components/schemas/RuleTag" - }, - "value" : { - "$ref" : "#/components/schemas/RuleValue" - } + "type" : { + "type" : "string" + }, + "width" : { + "$ref" : "#/components/schemas/MediaWidth" } }, - "RuleId" : { - "type" : "string", - "description" : "Unique identifier of this rule.", - "pattern" : "^[0-9]{1,19}$", - "example" : "120897978112909812" - }, - "RuleNoId" : { - "type" : "object", - "description" : "A user-provided stream filtering rule.", - "required" : [ - "value" - ], - "properties" : { - "tag" : { - "$ref" : "#/components/schemas/RuleTag" - }, - "value" : { - "$ref" : "#/components/schemas/RuleValue" - } + "discriminator" : { + "propertyName" : "type", + "mapping" : { + "animated_gif" : "#/components/schemas/AnimatedGif", + "photo" : "#/components/schemas/Photo", + "video" : "#/components/schemas/Video" } - }, - "RuleTag" : { - "type" : "string", - "description" : "A tag meant for the labeling of user provided rules.", - "example" : "Non-retweeted coffee Posts" - }, - "RuleValue" : { - "type" : "string", - "description" : "The filterlang value of the rule.", - "example" : "coffee -is:retweet" - }, - "RulesCapProblem" : { - "description" : "You have exceeded the maximum number of rules.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - } - ] - }, - "RulesCount" : { - "type" : "object", - "description" : "A count of user-provided stream filtering rules at the application and project levels.", - "properties" : { - "all_project_client_apps" : { - "$ref" : "#/components/schemas/AllProjectClientApps" - }, - "cap_per_client_app" : { - "type" : "integer", - "description" : "Cap of number of rules allowed per client application", - "format" : "int32" - }, - "cap_per_project" : { - "type" : "integer", - "description" : "Cap of number of rules allowed per project", - "format" : "int32" - }, - "client_app_rules_count" : { - "$ref" : "#/components/schemas/AppRulesCount" - }, - "project_rules_count" : { - "type" : "integer", - "description" : "Number of rules for project", - "format" : "int32" - } + } + }, + "MediaHeight" : { + "type" : "integer", + "description" : "The height of the media in pixels.", + "minimum" : 0 + }, + "MediaId" : { + "type" : "string", + "description" : "The unique identifier of this Media.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1146654567674912769" + }, + "MediaKey" : { + "type" : "string", + "description" : "The Media Key identifier for this attachment.", + "pattern" : "^([0-9]+)_([0-9]+)$" + }, + "MediaWidth" : { + "type" : "integer", + "description" : "The width of the media in pixels.", + "minimum" : 0 + }, + "MentionEntity" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/MentionFields" } - }, - "RulesLookupResponse" : { - "type" : "object", - "required" : [ - "meta" - ], - "properties" : { - "data" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/Rule" - } - }, - "meta" : { - "$ref" : "#/components/schemas/RulesResponseMetadata" - } + ] + }, + "MentionFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a User mention, and its start and end position within the text.", + "required" : [ + "username" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + }, + "username" : { + "$ref" : "#/components/schemas/UserName" } - }, - "RulesRequestSummary" : { - "oneOf" : [ - { - "type" : "object", - "description" : "A summary of the results of the addition of user-specified stream filtering rules.", - "required" : [ - "created", - "not_created", - "valid", - "invalid" - ], - "properties" : { - "created" : { - "type" : "integer", - "description" : "Number of user-specified stream filtering rules that were created.", - "format" : "int32", - "example" : 1 - }, - "invalid" : { - "type" : "integer", - "description" : "Number of invalid user-specified stream filtering rules.", - "format" : "int32", - "example" : 1 - }, - "not_created" : { - "type" : "integer", - "description" : "Number of user-specified stream filtering rules that were not created.", - "format" : "int32", - "example" : 1 - }, - "valid" : { - "type" : "integer", - "description" : "Number of valid user-specified stream filtering rules.", - "format" : "int32", - "example" : 1 - } - } - }, - { - "type" : "object", - "required" : [ - "deleted", - "not_deleted" - ], - "properties" : { - "deleted" : { - "type" : "integer", - "description" : "Number of user-specified stream filtering rules that were deleted.", - "format" : "int32" - }, - "not_deleted" : { - "type" : "integer", - "description" : "Number of user-specified stream filtering rules that were not deleted.", - "format" : "int32" - } + } + }, + "MuteUserMutationResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "muting" : { + "type" : "boolean" } } - ] - }, - "RulesResponseMetadata" : { - "type" : "object", - "required" : [ - "sent" - ], - "properties" : { - "next_token" : { - "$ref" : "#/components/schemas/NextToken" - }, - "result_count" : { - "type" : "integer", - "description" : "Number of Rules in result set.", - "format" : "int32" - }, - "sent" : { - "type" : "string" - }, - "summary" : { - "$ref" : "#/components/schemas/RulesRequestSummary" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "SearchCount" : { - "type" : "object", - "description" : "Represent a Search Count Result.", - "required" : [ - "end", - "start", - "tweet_count" - ], - "properties" : { - "end" : { - "$ref" : "#/components/schemas/End" - }, - "start" : { - "$ref" : "#/components/schemas/Start" - }, - "tweet_count" : { - "$ref" : "#/components/schemas/TweetCount" - } + } + }, + "MuteUserRequest" : { + "type" : "object", + "required" : [ + "target_user_id" + ], + "properties" : { + "target_user_id" : { + "$ref" : "#/components/schemas/UserId" } - }, - "Space" : { - "type" : "object", - "description" : "", - "required" : [ - "id", - "state" - ], - "properties" : { - "created_at" : { - "type" : "string", - "description" : "Creation time of the Space.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "creator_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "ended_at" : { - "type" : "string", - "description" : "End time of the Space.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "host_ids" : { - "type" : "array", - "description" : "The user ids for the hosts of the Space.", - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "id" : { - "$ref" : "#/components/schemas/SpaceId" - }, - "invited_user_ids" : { - "type" : "array", - "description" : "An array of user ids for people who were invited to a Space.", - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "is_ticketed" : { - "type" : "boolean", - "description" : "Denotes if the Space is a ticketed Space.", - "example" : "false" - }, - "lang" : { - "type" : "string", - "description" : "The language of the Space.", - "example" : "en" - }, - "participant_count" : { - "type" : "integer", - "description" : "The number of participants in a Space.", - "format" : "int32", - "example" : 10 - }, - "scheduled_start" : { - "type" : "string", - "description" : "A date time stamp for when a Space is scheduled to begin.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "speaker_ids" : { - "type" : "array", - "description" : "An array of user ids for people who were speakers in a Space.", - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "started_at" : { - "type" : "string", - "description" : "When the Space was started as a date string.", - "format" : "date-time", - "example" : "2021-7-14T04:35:55Z" - }, - "state" : { - "type" : "string", - "description" : "The current state of the Space.", - "enum" : [ - "live", - "scheduled", - "ended" - ], - "example" : "live" - }, - "subscriber_count" : { - "type" : "integer", - "description" : "The number of people who have either purchased a ticket or set a reminder for this Space.", - "format" : "int32", - "example" : 10 - }, - "title" : { - "type" : "string", - "description" : "The title of the Space.", - "example" : "Spaces are Awesome" - }, - "topics" : { - "type" : "array", - "description" : "The topics of a Space, as selected by its creator.", - "items" : { - "type" : "object", - "description" : "The X Topic object.", - "required" : [ - "id", - "name" - ], - "properties" : { - "description" : { - "type" : "string", - "description" : "The description of the given topic." - }, - "id" : { - "type" : "string", - "description" : "An ID suitable for use in the REST API." - }, - "name" : { - "type" : "string", - "description" : "The name of the given topic." - } - }, - "example" : { - "description" : "All about technology", - "id" : "848920371311001600", - "name" : "Technology" - } - } - }, - "updated_at" : { - "type" : "string", - "description" : "When the Space was last updated.", - "format" : "date-time", - "example" : "2021-7-14T04:35:55Z" - } + } + }, + "NewestId" : { + "type" : "string", + "description" : "The newest id in this response." + }, + "NextToken" : { + "type" : "string", + "description" : "The next token.", + "minLength" : 1 + }, + "NonCompliantRulesProblem" : { + "description" : "A problem that indicates the user's rule set is not compliant.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" } - }, - "SpaceId" : { - "type" : "string", - "description" : "The unique identifier of this Space.", - "pattern" : "^[a-zA-Z0-9]{1,13}$", - "example" : "1SLjjRYNejbKM" - }, - "Start" : { - "type" : "string", - "description" : "The start time of the bucket.", - "format" : "date-time" - }, - "StreamingLikeResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Like" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + ] + }, + "NoteTweetText" : { + "type" : "string", + "description" : "The note content of the Tweet.", + "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" + }, + "Oauth1PermissionsProblem" : { + "description" : "A problem that indicates your client application does not have the required OAuth1 permissions for the requested endpoint.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "OldestId" : { + "type" : "string", + "description" : "The oldest id in this response." + }, + "OperationalDisconnectProblem" : { + "description" : "You have been disconnected for operational reasons.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "disconnect_type" : { + "type" : "string", + "enum" : [ + "OperationalDisconnect", + "UpstreamOperationalDisconnect", + "ForceDisconnect", + "UpstreamUncleanDisconnect", + "SlowReader", + "InternalError", + "ClientApplicationStateDegraded", + "InvalidRules" + ] } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "StreamingTweetResponse" : { - "type" : "object", - "properties" : { - "data" : { - "$ref" : "#/components/schemas/Tweet" - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + ] + }, + "PaginationToken32" : { + "type" : "string", + "description" : "A base32 pagination token.", + "minLength" : 16 + }, + "PaginationToken36" : { + "type" : "string", + "description" : "A base36 pagination token.", + "minLength" : 1 + }, + "PaginationTokenLong" : { + "type" : "string", + "description" : "A 'long' pagination token.", + "minLength" : 1, + "maxLength" : 19 + }, + "Photo" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "alt_text" : { + "type" : "string" + }, + "url" : { + "type" : "string", + "format" : "uri" } - }, - "includes" : { - "$ref" : "#/components/schemas/Expansions" } } - }, - "Topic" : { - "type" : "object", - "description" : "The topic of a Space, as selected by its creator.", - "required" : [ - "id", - "name" - ], - "properties" : { - "description" : { - "type" : "string", - "description" : "The description of the given topic.", - "example" : "All about technology" - }, - "id" : { - "$ref" : "#/components/schemas/TopicId" - }, - "name" : { - "type" : "string", - "description" : "The name of the given topic.", - "example" : "Technology" + ] + }, + "Place" : { + "type" : "object", + "required" : [ + "id", + "full_name" + ], + "properties" : { + "contained_within" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/PlaceId" } + }, + "country" : { + "type" : "string", + "description" : "The full name of the county in which this place exists.", + "example" : "United States" + }, + "country_code" : { + "$ref" : "#/components/schemas/CountryCode" + }, + "full_name" : { + "type" : "string", + "description" : "The full name of this place.", + "example" : "Lakewood, CO" + }, + "geo" : { + "$ref" : "#/components/schemas/Geo" + }, + "id" : { + "$ref" : "#/components/schemas/PlaceId" + }, + "name" : { + "type" : "string", + "description" : "The human readable name of this place.", + "example" : "Lakewood" + }, + "place_type" : { + "$ref" : "#/components/schemas/PlaceType" } - }, - "TopicId" : { - "type" : "string", - "description" : "Unique identifier of this Topic." - }, - "Trend" : { - "type" : "object", - "description" : "A trend.", - "properties" : { - "trend_name" : { - "type" : "string", - "description" : "Name of the trend." - }, - "tweet_count" : { - "type" : "integer", - "description" : "Number of Posts in this trend.", - "format" : "int32" + } + }, + "PlaceId" : { + "type" : "string", + "description" : "The identifier for this place.", + "example" : "f7eb2fa2fea288b1" + }, + "PlaceType" : { + "type" : "string", + "enum" : [ + "poi", + "neighborhood", + "city", + "admin", + "country", + "unknown" + ], + "example" : "city" + }, + "Point" : { + "type" : "object", + "description" : "A [GeoJson Point](https://tools.ietf.org/html/rfc7946#section-3.1.2) geometry object.", + "required" : [ + "type", + "coordinates" + ], + "properties" : { + "coordinates" : { + "$ref" : "#/components/schemas/Position" + }, + "type" : { + "type" : "string", + "enum" : [ + "Point" + ], + "example" : "Point" + } + } + }, + "Poll" : { + "type" : "object", + "description" : "Represent a Poll attached to a Tweet.", + "required" : [ + "id", + "options" + ], + "properties" : { + "duration_minutes" : { + "type" : "integer", + "minimum" : 5, + "maximum" : 10080, + "format" : "int32" + }, + "end_datetime" : { + "type" : "string", + "format" : "date-time" + }, + "id" : { + "$ref" : "#/components/schemas/PollId" + }, + "options" : { + "type" : "array", + "minItems" : 2, + "maxItems" : 4, + "items" : { + "$ref" : "#/components/schemas/PollOption" } + }, + "voting_status" : { + "type" : "string", + "enum" : [ + "open", + "closed" + ] } - }, - "Tweet" : { - "type" : "object", - "properties" : { - "attachments" : { - "type" : "object", - "description" : "Specifies the type of attachments (if any) present in this Tweet.", - "properties" : { - "media_keys" : { - "type" : "array", - "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/MediaKey" - } - }, - "media_source_tweet_id" : { - "type" : "array", - "description" : "A list of Posts the media on this Tweet was originally posted in. For example, if the media on a tweet is re-used in another Tweet, this refers to the original, source Tweet..", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/TweetId" - } - }, - "poll_ids" : { - "type" : "array", - "description" : "A list of poll IDs (if polls are attached).", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/PollId" - } - } - } - }, - "author_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "context_annotations" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/ContextAnnotation" - } - }, - "conversation_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "created_at" : { - "type" : "string", - "description" : "Creation time of the Tweet.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "edit_controls" : { - "type" : "object", - "required" : [ - "is_edit_eligible", - "editable_until", - "edits_remaining" - ], - "properties" : { - "editable_until" : { - "type" : "string", - "description" : "Time when Tweet is no longer editable.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "edits_remaining" : { - "type" : "integer", - "description" : "Number of times this Tweet can be edited." - }, - "is_edit_eligible" : { - "type" : "boolean", - "description" : "Indicates if this Tweet is eligible to be edited.", - "example" : false - } - } - }, - "edit_history_tweet_ids" : { - "type" : "array", - "description" : "A list of Tweet Ids in this Tweet chain.", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/TweetId" - } - }, - "entities" : { - "$ref" : "#/components/schemas/FullTextEntities" - }, - "geo" : { - "type" : "object", - "description" : "The location tagged on the Tweet, if the user provided one.", - "properties" : { - "coordinates" : { - "$ref" : "#/components/schemas/Point" - }, - "place_id" : { - "$ref" : "#/components/schemas/PlaceId" - } - } - }, - "id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "in_reply_to_user_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "lang" : { - "type" : "string", - "description" : "Language of the Tweet, if detected by X. Returned as a BCP47 language tag.", - "example" : "en" - }, - "non_public_metrics" : { - "type" : "object", - "description" : "Nonpublic engagement metrics for the Tweet at the time of the request.", - "properties" : { - "impression_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been viewed.", - "format" : "int32" - } - } - }, - "note_tweet" : { - "type" : "object", - "description" : "The full-content of the Tweet, including text beyond 280 characters.", - "properties" : { - "entities" : { - "type" : "object", - "properties" : { - "cashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/CashtagEntity" - } - }, - "hashtags" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/HashtagEntity" - } - }, - "mentions" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/MentionEntity" - } - }, - "urls" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UrlEntity" - } - } - } - }, - "text" : { - "$ref" : "#/components/schemas/NoteTweetText" - } - } - }, - "organic_metrics" : { - "type" : "object", - "description" : "Organic nonpublic engagement metrics for the Tweet at the time of the request.", - "required" : [ - "impression_count", - "retweet_count", - "reply_count", - "like_count" - ], - "properties" : { - "impression_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been viewed." - }, - "like_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been liked." - }, - "reply_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been replied to." - }, - "retweet_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been Retweeted." - } - } - }, - "possibly_sensitive" : { - "type" : "boolean", - "description" : "Indicates if this Tweet contains URLs marked as sensitive, for example content suitable for mature audiences.", - "example" : false - }, - "promoted_metrics" : { - "type" : "object", - "description" : "Promoted nonpublic engagement metrics for the Tweet at the time of the request.", - "properties" : { - "impression_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been viewed.", - "format" : "int32" - }, - "like_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been liked.", - "format" : "int32" - }, - "reply_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been replied to.", - "format" : "int32" - }, - "retweet_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been Retweeted.", - "format" : "int32" - } + } + }, + "PollId" : { + "type" : "string", + "description" : "Unique identifier of this poll.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1365059861688410112" + }, + "PollOption" : { + "type" : "object", + "description" : "Describes a choice in a Poll object.", + "required" : [ + "position", + "label", + "votes" + ], + "properties" : { + "label" : { + "$ref" : "#/components/schemas/PollOptionLabel" + }, + "position" : { + "type" : "integer", + "description" : "Position of this choice in the poll." + }, + "votes" : { + "type" : "integer", + "description" : "Number of users who voted for this choice." + } + } + }, + "PollOptionLabel" : { + "type" : "string", + "description" : "The text of a poll choice.", + "minLength" : 1, + "maxLength" : 25 + }, + "Position" : { + "type" : "array", + "description" : "A [GeoJson Position](https://tools.ietf.org/html/rfc7946#section-3.1.1) in the format `[longitude,latitude]`.", + "minItems" : 2, + "maxItems" : 2, + "items" : { + "type" : "number" + }, + "example" : [ + -105.18816086351444, + 40.247749999999996 + ] + }, + "PreviousToken" : { + "type" : "string", + "description" : "The previous token.", + "minLength" : 1 + }, + "Problem" : { + "type" : "object", + "description" : "An HTTP Problem Details object, as defined in IETF RFC 7807 (https://tools.ietf.org/html/rfc7807).", + "required" : [ + "type", + "title" + ], + "properties" : { + "detail" : { + "type" : "string" + }, + "status" : { + "type" : "integer" + }, + "title" : { + "type" : "string" + }, + "type" : { + "type" : "string" + } + }, + "discriminator" : { + "propertyName" : "type", + "mapping" : { + "about:blank" : "#/components/schemas/GenericProblem", + "https://api.twitter.com/2/problems/client-disconnected" : "#/components/schemas/ClientDisconnectedProblem", + "https://api.twitter.com/2/problems/client-forbidden" : "#/components/schemas/ClientForbiddenProblem", + "https://api.twitter.com/2/problems/conflict" : "#/components/schemas/ConflictProblem", + "https://api.twitter.com/2/problems/disallowed-resource" : "#/components/schemas/DisallowedResourceProblem", + "https://api.twitter.com/2/problems/duplicate-rules" : "#/components/schemas/DuplicateRuleProblem", + "https://api.twitter.com/2/problems/invalid-request" : "#/components/schemas/InvalidRequestProblem", + "https://api.twitter.com/2/problems/invalid-rules" : "#/components/schemas/InvalidRuleProblem", + "https://api.twitter.com/2/problems/noncompliant-rules" : "#/components/schemas/NonCompliantRulesProblem", + "https://api.twitter.com/2/problems/not-authorized-for-field" : "#/components/schemas/FieldUnauthorizedProblem", + "https://api.twitter.com/2/problems/not-authorized-for-resource" : "#/components/schemas/ResourceUnauthorizedProblem", + "https://api.twitter.com/2/problems/oauth1-permissions" : "#/components/schemas/Oauth1PermissionsProblem", + "https://api.twitter.com/2/problems/operational-disconnect" : "#/components/schemas/OperationalDisconnectProblem", + "https://api.twitter.com/2/problems/resource-not-found" : "#/components/schemas/ResourceNotFoundProblem", + "https://api.twitter.com/2/problems/resource-unavailable" : "#/components/schemas/ResourceUnavailableProblem", + "https://api.twitter.com/2/problems/rule-cap" : "#/components/schemas/RulesCapProblem", + "https://api.twitter.com/2/problems/streaming-connection" : "#/components/schemas/ConnectionExceptionProblem", + "https://api.twitter.com/2/problems/unsupported-authentication" : "#/components/schemas/UnsupportedAuthenticationProblem", + "https://api.twitter.com/2/problems/usage-capped" : "#/components/schemas/UsageCapExceededProblem" + } + } + }, + "ReplySettings" : { + "type" : "string", + "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, and following.", + "pattern" : "^[A-Za-z]{1,12}$", + "enum" : [ + "everyone", + "mentionedUsers", + "following", + "other" + ] + }, + "ReplySettingsWithVerifiedUsers" : { + "type" : "string", + "description" : "Shows who can reply a Tweet. Fields returned are everyone, mentioned_users, subscribers, verified and following.", + "pattern" : "^[A-Za-z]{1,12}$", + "enum" : [ + "everyone", + "mentionedUsers", + "following", + "other", + "subscribers", + "verified" + ] + }, + "ResourceNotFoundProblem" : { + "description" : "A problem that indicates that a given Tweet, User, etc. does not exist.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "parameter", + "value", + "resource_id", + "resource_type" + ], + "properties" : { + "parameter" : { + "type" : "string", + "minLength" : 1 + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "value" : { + "type" : "string", + "description" : "Value will match the schema of the field." } - }, - "public_metrics" : { - "type" : "object", - "description" : "Engagement metrics for the Tweet at the time of the request.", - "required" : [ - "retweet_count", - "reply_count", - "like_count", - "impression_count", - "bookmark_count" - ], - "properties" : { - "bookmark_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been bookmarked.", - "format" : "int32" - }, - "impression_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been viewed.", - "format" : "int32" - }, - "like_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been liked." - }, - "quote_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been quoted." - }, - "reply_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been replied to." - }, - "retweet_count" : { - "type" : "integer", - "description" : "Number of times this Tweet has been Retweeted." - } + } + } + ] + }, + "ResourceUnauthorizedProblem" : { + "description" : "A problem that indicates you are not allowed to see a particular Tweet, User, etc.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "value", + "resource_id", + "resource_type", + "section", + "parameter" + ], + "properties" : { + "parameter" : { + "type" : "string" + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] + }, + "section" : { + "type" : "string", + "enum" : [ + "data", + "includes" + ] + }, + "value" : { + "type" : "string" } - }, - "referenced_tweets" : { - "type" : "array", - "description" : "A list of Posts this Tweet refers to. For example, if the parent Tweet is a Retweet, a Quoted Tweet or a Reply, it will include the related Tweet referenced to by its parent.", - "minItems" : 1, - "items" : { - "type" : "object", - "required" : [ - "type", - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "type" : { - "type" : "string", - "enum" : [ - "retweeted", - "quoted", - "replied_to" - ] - } - } + } + } + ] + }, + "ResourceUnavailableProblem" : { + "description" : "A problem that indicates a particular Tweet, User, etc. is not available to you.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "required" : [ + "parameter", + "resource_id", + "resource_type" + ], + "properties" : { + "parameter" : { + "type" : "string", + "minLength" : 1 + }, + "resource_id" : { + "type" : "string" + }, + "resource_type" : { + "type" : "string", + "enum" : [ + "user", + "tweet", + "media", + "list", + "space" + ] } - }, - "reply_settings" : { - "$ref" : "#/components/schemas/ReplySettingsWithVerifiedUsers" - }, - "scopes" : { - "type" : "object", - "description" : "The scopes for this tweet", - "properties" : { - "followers" : { - "type" : "boolean", - "description" : "Indicates if this Tweet is viewable by followers without the Tweet ID", - "example" : false - } + } + } + ] + }, + "ResultCount" : { + "type" : "integer", + "description" : "The number of results returned in this response.", + "format" : "int32" + }, + "Rule" : { + "type" : "object", + "description" : "A user-provided stream filtering rule.", + "required" : [ + "value" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/RuleId" + }, + "tag" : { + "$ref" : "#/components/schemas/RuleTag" + }, + "value" : { + "$ref" : "#/components/schemas/RuleValue" + } + } + }, + "RuleId" : { + "type" : "string", + "description" : "Unique identifier of this rule.", + "pattern" : "^[0-9]{1,19}$", + "example" : "120897978112909812" + }, + "RuleNoId" : { + "type" : "object", + "description" : "A user-provided stream filtering rule.", + "required" : [ + "value" + ], + "properties" : { + "tag" : { + "$ref" : "#/components/schemas/RuleTag" + }, + "value" : { + "$ref" : "#/components/schemas/RuleValue" + } + } + }, + "RuleTag" : { + "type" : "string", + "description" : "A tag meant for the labeling of user provided rules.", + "example" : "Non-retweeted coffee Posts" + }, + "RuleValue" : { + "type" : "string", + "description" : "The filterlang value of the rule.", + "example" : "coffee -is:retweet" + }, + "RulesCapProblem" : { + "description" : "You have exceeded the maximum number of rules.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "RulesCount" : { + "type" : "object", + "description" : "A count of user-provided stream filtering rules at the application and project levels.", + "properties" : { + "all_project_client_apps" : { + "$ref" : "#/components/schemas/AllProjectClientApps" + }, + "cap_per_client_app" : { + "type" : "integer", + "description" : "Cap of number of rules allowed per client application", + "format" : "int32" + }, + "cap_per_project" : { + "type" : "integer", + "description" : "Cap of number of rules allowed per project", + "format" : "int32" + }, + "client_app_rules_count" : { + "$ref" : "#/components/schemas/AppRulesCount" + }, + "project_rules_count" : { + "type" : "integer", + "description" : "Number of rules for project", + "format" : "int32" + } + } + }, + "RulesLookupResponse" : { + "type" : "object", + "required" : [ + "meta" + ], + "properties" : { + "data" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Rule" + } + }, + "meta" : { + "$ref" : "#/components/schemas/RulesResponseMetadata" + } + } + }, + "RulesRequestSummary" : { + "oneOf" : [ + { + "type" : "object", + "description" : "A summary of the results of the addition of user-specified stream filtering rules.", + "required" : [ + "created", + "not_created", + "valid", + "invalid" + ], + "properties" : { + "created" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were created.", + "format" : "int32", + "example" : 1 + }, + "invalid" : { + "type" : "integer", + "description" : "Number of invalid user-specified stream filtering rules.", + "format" : "int32", + "example" : 1 + }, + "not_created" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were not created.", + "format" : "int32", + "example" : 1 + }, + "valid" : { + "type" : "integer", + "description" : "Number of valid user-specified stream filtering rules.", + "format" : "int32", + "example" : 1 } - }, - "source" : { - "type" : "string", - "description" : "This is deprecated." - }, - "text" : { - "$ref" : "#/components/schemas/TweetText" - }, - "username" : { - "$ref" : "#/components/schemas/UserName" - }, - "withheld" : { - "$ref" : "#/components/schemas/TweetWithheld" } }, - "example" : { - "author_id" : "2244994945", - "created_at" : "Wed Jan 06 18:40:40 +0000 2021", - "id" : "1346889436626259968", - "text" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i", - "username" : "XDevelopers" + { + "type" : "object", + "required" : [ + "deleted", + "not_deleted" + ], + "properties" : { + "deleted" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were deleted.", + "format" : "int32" + }, + "not_deleted" : { + "type" : "integer", + "description" : "Number of user-specified stream filtering rules that were not deleted.", + "format" : "int32" + } + } } - }, - "TweetComplianceData" : { - "description" : "Tweet compliance data.", - "oneOf" : [ - { - "$ref" : "#/components/schemas/TweetDeleteComplianceSchema" - }, - { - "$ref" : "#/components/schemas/TweetWithheldComplianceSchema" - }, - { - "$ref" : "#/components/schemas/TweetDropComplianceSchema" - }, - { - "$ref" : "#/components/schemas/TweetUndropComplianceSchema" - }, - { - "$ref" : "#/components/schemas/TweetEditComplianceSchema" + ] + }, + "RulesResponseMetadata" : { + "type" : "object", + "required" : [ + "sent" + ], + "properties" : { + "next_token" : { + "$ref" : "#/components/schemas/NextToken" + }, + "result_count" : { + "type" : "integer", + "description" : "Number of Rules in result set.", + "format" : "int32" + }, + "sent" : { + "type" : "string" + }, + "summary" : { + "$ref" : "#/components/schemas/RulesRequestSummary" + } + } + }, + "SearchCount" : { + "type" : "object", + "description" : "Represent a Search Count Result.", + "required" : [ + "end", + "start", + "tweet_count" + ], + "properties" : { + "end" : { + "$ref" : "#/components/schemas/End" + }, + "start" : { + "$ref" : "#/components/schemas/Start" + }, + "tweet_count" : { + "$ref" : "#/components/schemas/TweetCount" + } + } + }, + "Space" : { + "type" : "object", + "description" : "", + "required" : [ + "id", + "state" + ], + "properties" : { + "created_at" : { + "type" : "string", + "description" : "Creation time of the Space.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "creator_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "ended_at" : { + "type" : "string", + "description" : "End time of the Space.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "host_ids" : { + "type" : "array", + "description" : "The user ids for the hosts of the Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" } - ] - }, - "TweetComplianceSchema" : { - "type" : "object", - "required" : [ - "tweet", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "quote_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "tweet" : { + }, + "id" : { + "$ref" : "#/components/schemas/SpaceId" + }, + "invited_user_ids" : { + "type" : "array", + "description" : "An array of user ids for people who were invited to a Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "is_ticketed" : { + "type" : "boolean", + "description" : "Denotes if the Space is a ticketed Space.", + "example" : "false" + }, + "lang" : { + "type" : "string", + "description" : "The language of the Space.", + "example" : "en" + }, + "participant_count" : { + "type" : "integer", + "description" : "The number of participants in a Space.", + "format" : "int32", + "example" : 10 + }, + "scheduled_start" : { + "type" : "string", + "description" : "A date time stamp for when a Space is scheduled to begin.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "speaker_ids" : { + "type" : "array", + "description" : "An array of user ids for people who were speakers in a Space.", + "items" : { + "$ref" : "#/components/schemas/UserId" + } + }, + "started_at" : { + "type" : "string", + "description" : "When the Space was started as a date string.", + "format" : "date-time", + "example" : "2021-7-14T04:35:55Z" + }, + "state" : { + "type" : "string", + "description" : "The current state of the Space.", + "enum" : [ + "live", + "scheduled", + "ended" + ], + "example" : "live" + }, + "subscriber_count" : { + "type" : "integer", + "description" : "The number of people who have either purchased a ticket or set a reminder for this Space.", + "format" : "int32", + "example" : 10 + }, + "title" : { + "type" : "string", + "description" : "The title of the Space.", + "example" : "Spaces are Awesome" + }, + "topics" : { + "type" : "array", + "description" : "The topics of a Space, as selected by its creator.", + "items" : { "type" : "object", + "description" : "The X Topic object.", "required" : [ "id", - "author_id" + "name" ], "properties" : { - "author_id" : { - "$ref" : "#/components/schemas/UserId" + "description" : { + "type" : "string", + "description" : "The description of the given topic." }, "id" : { - "$ref" : "#/components/schemas/TweetId" + "type" : "string", + "description" : "An ID suitable for use in the REST API." + }, + "name" : { + "type" : "string", + "description" : "The name of the given topic." } + }, + "example" : { + "description" : "All about technology", + "id" : "848920371311001600", + "name" : "Technology" } } + }, + "updated_at" : { + "type" : "string", + "description" : "When the Space was last updated.", + "format" : "date-time", + "example" : "2021-7-14T04:35:55Z" } - }, - "TweetComplianceStreamResponse" : { - "description" : "Tweet compliance stream events.", - "oneOf" : [ - { - "type" : "object", - "description" : "Compliance event.", - "required" : [ - "data" - ], - "properties" : { - "data" : { - "$ref" : "#/components/schemas/TweetComplianceData" - } - } - }, - { - "type" : "object", - "required" : [ - "errors" - ], - "properties" : { - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - } - } + } + }, + "SpaceId" : { + "type" : "string", + "description" : "The unique identifier of this Space.", + "pattern" : "^[a-zA-Z0-9]{1,13}$", + "example" : "1SLjjRYNejbKM" + }, + "Start" : { + "type" : "string", + "description" : "The start time of the bucket.", + "format" : "date-time" + }, + "StreamingLikeResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Like" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } - ] - }, - "TweetCount" : { - "type" : "integer", - "description" : "The count for the bucket." - }, - "TweetCreateRequest" : { - "type" : "object", - "properties" : { - "card_uri" : { - "type" : "string", - "description" : "Card Uri Parameter. This is mutually exclusive from Quote Tweet Id, Poll, Media, and Direct Message Deep Link." - }, - "direct_message_deep_link" : { - "type" : "string", - "description" : "Link to take the conversation from the public timeline to a private Direct Message." - }, - "for_super_followers_only" : { - "type" : "boolean", - "description" : "Exclusive Tweet for super followers.", - "default" : false - }, - "geo" : { - "type" : "object", - "description" : "Place ID being attached to the Tweet for geo location.", - "properties" : { - "place_id" : { - "type" : "string" - } - }, - "additionalProperties" : false - }, - "media" : { - "type" : "object", - "description" : "Media information being attached to created Tweet. This is mutually exclusive from Quote Tweet Id, Poll, and Card URI.", - "required" : [ - "media_ids" - ], - "properties" : { - "media_ids" : { - "type" : "array", - "description" : "A list of Media Ids to be attached to a created Tweet.", - "minItems" : 1, - "maxItems" : 4, - "items" : { - "$ref" : "#/components/schemas/MediaId" - } - }, - "tagged_user_ids" : { - "type" : "array", - "description" : "A list of User Ids to be tagged in the media for created Tweet.", - "minItems" : 0, - "maxItems" : 10, - "items" : { - "$ref" : "#/components/schemas/UserId" - } - } - }, - "additionalProperties" : false - }, - "nullcast" : { - "type" : "boolean", - "description" : "Nullcasted (promoted-only) Posts do not appear in the public timeline and are not served to followers.", - "default" : false - }, - "poll" : { - "type" : "object", - "description" : "Poll options for a Tweet with a poll. This is mutually exclusive from Media, Quote Tweet Id, and Card URI.", - "required" : [ - "options", - "duration_minutes" - ], - "properties" : { - "duration_minutes" : { - "type" : "integer", - "description" : "Duration of the poll in minutes.", - "minimum" : 5, - "maximum" : 10080, - "format" : "int32" - }, - "options" : { - "type" : "array", - "minItems" : 2, - "maxItems" : 4, - "items" : { - "type" : "string", - "description" : "The text of a poll choice.", - "minLength" : 1, - "maxLength" : 25 - } - }, - "reply_settings" : { - "type" : "string", - "description" : "Settings to indicate who can reply to the Tweet.", - "enum" : [ - "following", - "mentionedUsers" - ] + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "StreamingTweetResponse" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tweet" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + }, + "includes" : { + "$ref" : "#/components/schemas/Expansions" + } + } + }, + "Topic" : { + "type" : "object", + "description" : "The topic of a Space, as selected by its creator.", + "required" : [ + "id", + "name" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "The description of the given topic.", + "example" : "All about technology" + }, + "id" : { + "$ref" : "#/components/schemas/TopicId" + }, + "name" : { + "type" : "string", + "description" : "The name of the given topic.", + "example" : "Technology" + } + } + }, + "TopicId" : { + "type" : "string", + "description" : "Unique identifier of this Topic." + }, + "Trend" : { + "type" : "object", + "description" : "A trend.", + "properties" : { + "trend_name" : { + "type" : "string", + "description" : "Name of the trend." + }, + "tweet_count" : { + "type" : "integer", + "description" : "Number of Posts in this trend.", + "format" : "int32" + } + } + }, + "Tweet" : { + "type" : "object", + "properties" : { + "attachments" : { + "type" : "object", + "description" : "Specifies the type of attachments (if any) present in this Tweet.", + "properties" : { + "media_keys" : { + "type" : "array", + "description" : "A list of Media Keys for each one of the media attachments (if media are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MediaKey" } }, - "additionalProperties" : false - }, - "quote_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "reply" : { - "type" : "object", - "description" : "Tweet information of the Tweet being replied to.", - "required" : [ - "in_reply_to_tweet_id" - ], - "properties" : { - "exclude_reply_user_ids" : { - "type" : "array", - "description" : "A list of User Ids to be excluded from the reply Tweet.", - "items" : { - "$ref" : "#/components/schemas/UserId" - } - }, - "in_reply_to_tweet_id" : { + "media_source_tweet_id" : { + "type" : "array", + "description" : "A list of Posts the media on this Tweet was originally posted in. For example, if the media on a tweet is re-used in another Tweet, this refers to the original, source Tweet..", + "minItems" : 1, + "items" : { "$ref" : "#/components/schemas/TweetId" } }, - "additionalProperties" : false - }, - "reply_settings" : { - "type" : "string", - "description" : "Settings to indicate who can reply to the Tweet.", - "enum" : [ - "following", - "mentionedUsers", - "subscribers" - ] - }, - "text" : { - "$ref" : "#/components/schemas/TweetText" + "poll_ids" : { + "type" : "array", + "description" : "A list of poll IDs (if polls are attached).", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/PollId" + } + } } }, - "additionalProperties" : false - }, - "TweetCreateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "required" : [ - "id", - "text" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "text" : { - "$ref" : "#/components/schemas/TweetText" - } + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "context_annotations" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ContextAnnotation" + } + }, + "conversation_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "created_at" : { + "type" : "string", + "description" : "Creation time of the Tweet.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "edit_controls" : { + "type" : "object", + "required" : [ + "is_edit_eligible", + "editable_until", + "edits_remaining" + ], + "properties" : { + "editable_until" : { + "type" : "string", + "description" : "Time when Tweet is no longer editable.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "edits_remaining" : { + "type" : "integer", + "description" : "Number of times this Tweet can be edited." + }, + "is_edit_eligible" : { + "type" : "boolean", + "description" : "Indicates if this Tweet is eligible to be edited.", + "example" : false } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "edit_history_tweet_ids" : { + "type" : "array", + "description" : "A list of Tweet Ids in this Tweet chain.", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "entities" : { + "$ref" : "#/components/schemas/FullTextEntities" + }, + "geo" : { + "type" : "object", + "description" : "The location tagged on the Tweet, if the user provided one.", + "properties" : { + "coordinates" : { + "$ref" : "#/components/schemas/Point" + }, + "place_id" : { + "$ref" : "#/components/schemas/PlaceId" } } - } - }, - "TweetDeleteComplianceSchema" : { - "type" : "object", - "required" : [ - "delete" - ], - "properties" : { - "delete" : { - "$ref" : "#/components/schemas/TweetComplianceSchema" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "in_reply_to_user_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "lang" : { + "type" : "string", + "description" : "Language of the Tweet, if detected by X. Returned as a BCP47 language tag.", + "example" : "en" + }, + "non_public_metrics" : { + "type" : "object", + "description" : "Nonpublic engagement metrics for the Tweet at the time of the request.", + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + } } - } - }, - "TweetDeleteResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "required" : [ - "deleted" - ], - "properties" : { - "deleted" : { - "type" : "boolean" + }, + "note_tweet" : { + "type" : "object", + "description" : "The full-content of the Tweet, including text beyond 280 characters.", + "properties" : { + "entities" : { + "type" : "object", + "properties" : { + "cashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CashtagEntity" + } + }, + "hashtags" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/HashtagEntity" + } + }, + "mentions" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/MentionEntity" + } + }, + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" + } + } } + }, + "text" : { + "$ref" : "#/components/schemas/NoteTweetText" } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "organic_metrics" : { + "type" : "object", + "description" : "Organic nonpublic engagement metrics for the Tweet at the time of the request.", + "required" : [ + "impression_count", + "retweet_count", + "reply_count", + "like_count" + ], + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed." + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked." + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to." + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted." } } - } - }, - "TweetDropComplianceSchema" : { - "type" : "object", - "required" : [ - "drop" - ], - "properties" : { - "drop" : { - "$ref" : "#/components/schemas/TweetComplianceSchema" + }, + "possibly_sensitive" : { + "type" : "boolean", + "description" : "Indicates if this Tweet contains URLs marked as sensitive, for example content suitable for mature audiences.", + "example" : false + }, + "promoted_metrics" : { + "type" : "object", + "description" : "Promoted nonpublic engagement metrics for the Tweet at the time of the request.", + "properties" : { + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked.", + "format" : "int32" + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to.", + "format" : "int32" + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted.", + "format" : "int32" + } } - } - }, - "TweetEditComplianceObjectSchema" : { - "type" : "object", - "required" : [ - "tweet", - "event_at", - "initial_tweet_id", - "edit_tweet_ids" - ], - "properties" : { - "edit_tweet_ids" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/TweetId" + }, + "public_metrics" : { + "type" : "object", + "description" : "Engagement metrics for the Tweet at the time of the request.", + "required" : [ + "retweet_count", + "reply_count", + "like_count", + "impression_count", + "bookmark_count" + ], + "properties" : { + "bookmark_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been bookmarked.", + "format" : "int32" + }, + "impression_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been viewed.", + "format" : "int32" + }, + "like_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been liked." + }, + "quote_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been quoted." + }, + "reply_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been replied to." + }, + "retweet_count" : { + "type" : "integer", + "description" : "Number of times this Tweet has been Retweeted." } - }, - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "initial_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "tweet" : { + } + }, + "referenced_tweets" : { + "type" : "array", + "description" : "A list of Posts this Tweet refers to. For example, if the parent Tweet is a Retweet, a Quoted Tweet or a Reply, it will include the related Tweet referenced to by its parent.", + "minItems" : 1, + "items" : { "type" : "object", "required" : [ + "type", "id" ], "properties" : { "id" : { "$ref" : "#/components/schemas/TweetId" + }, + "type" : { + "type" : "string", + "enum" : [ + "retweeted", + "quoted", + "replied_to" + ] } } } - } - }, - "TweetEditComplianceSchema" : { - "type" : "object", - "required" : [ - "tweet_edit" - ], - "properties" : { - "tweet_edit" : { - "$ref" : "#/components/schemas/TweetEditComplianceObjectSchema" + }, + "reply_settings" : { + "$ref" : "#/components/schemas/ReplySettingsWithVerifiedUsers" + }, + "scopes" : { + "type" : "object", + "description" : "The scopes for this tweet", + "properties" : { + "followers" : { + "type" : "boolean", + "description" : "Indicates if this Tweet is viewable by followers without the Tweet ID", + "example" : false + } } + }, + "source" : { + "type" : "string", + "description" : "This is deprecated." + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" + }, + "username" : { + "$ref" : "#/components/schemas/UserName" + }, + "withheld" : { + "$ref" : "#/components/schemas/TweetWithheld" } }, - "TweetHideRequest" : { - "type" : "object", - "required" : [ - "hidden" - ], - "properties" : { - "hidden" : { - "type" : "boolean" - } + "example" : { + "author_id" : "2244994945", + "created_at" : "Wed Jan 06 18:40:40 +0000 2021", + "id" : "1346889436626259968", + "text" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i", + "username" : "XDevelopers" + } + }, + "TweetComplianceData" : { + "description" : "Tweet compliance data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/TweetDeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetWithheldComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetDropComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetUndropComplianceSchema" + }, + { + "$ref" : "#/components/schemas/TweetEditComplianceSchema" } - }, - "TweetHideResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "hidden" : { - "type" : "boolean" - } + ] + }, + "TweetComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" } } } - }, - "TweetId" : { - "type" : "string", - "description" : "Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", - "pattern" : "^[0-9]{1,19}$", - "example" : "1346889436626259968" - }, - "TweetLabelData" : { - "description" : "Tweet label data.", - "oneOf" : [ - { - "$ref" : "#/components/schemas/TweetNoticeSchema" - }, - { - "$ref" : "#/components/schemas/TweetUnviewableSchema" - } - ] - }, - "TweetLabelStreamResponse" : { - "description" : "Tweet label stream events.", - "oneOf" : [ - { - "type" : "object", - "description" : "Tweet Label event.", - "required" : [ - "data" - ], - "properties" : { - "data" : { - "$ref" : "#/components/schemas/TweetLabelData" - } - } - }, - { - "type" : "object", - "required" : [ - "errors" - ], - "properties" : { - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } - } - } - } - ] - }, - "TweetNotice" : { - "type" : "object", - "required" : [ - "tweet", - "event_type", - "event_at", - "application" - ], - "properties" : { - "application" : { - "type" : "string", - "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", - "example" : "apply" - }, - "details" : { - "type" : "string", - "description" : "Information shown on the Tweet label" - }, - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "event_type" : { - "type" : "string", - "description" : "The type of label on the Tweet", - "example" : "misleading" - }, - "extended_details_url" : { - "type" : "string", - "description" : "Link to more information about this kind of label" - }, - "label_title" : { - "type" : "string", - "description" : "Title/header of the Tweet label" - }, - "tweet" : { - "type" : "object", - "required" : [ - "id", - "author_id" - ], - "properties" : { - "author_id" : { - "$ref" : "#/components/schemas/UserId" - }, - "id" : { - "$ref" : "#/components/schemas/TweetId" - } + } + }, + "TweetComplianceStreamResponse" : { + "description" : "Tweet compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/TweetComplianceData" } } - } - }, - "TweetNoticeSchema" : { - "type" : "object", - "required" : [ - "public_tweet_notice" - ], - "properties" : { - "public_tweet_notice" : { - "$ref" : "#/components/schemas/TweetNotice" + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } } } - }, - "TweetTakedownComplianceSchema" : { - "type" : "object", - "required" : [ - "tweet", - "withheld_in_countries", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "quote_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" + ] + }, + "TweetCount" : { + "type" : "integer", + "description" : "The count for the bucket." + }, + "TweetCreateRequest" : { + "type" : "object", + "properties" : { + "card_uri" : { + "type" : "string", + "description" : "Card Uri Parameter. This is mutually exclusive from Quote Tweet Id, Poll, Media, and Direct Message Deep Link." + }, + "direct_message_deep_link" : { + "type" : "string", + "description" : "Link to take the conversation from the public timeline to a private Direct Message." + }, + "for_super_followers_only" : { + "type" : "boolean", + "description" : "Exclusive Tweet for super followers.", + "default" : false + }, + "geo" : { + "type" : "object", + "description" : "Place ID being attached to the Tweet for geo location.", + "properties" : { + "place_id" : { + "type" : "string" + } }, - "tweet" : { - "type" : "object", - "required" : [ - "id", - "author_id" - ], - "properties" : { - "author_id" : { + "additionalProperties" : false + }, + "media" : { + "type" : "object", + "description" : "Media information being attached to created Tweet. This is mutually exclusive from Quote Tweet Id, Poll, and Card URI.", + "required" : [ + "media_ids" + ], + "properties" : { + "media_ids" : { + "type" : "array", + "description" : "A list of Media Ids to be attached to a created Tweet.", + "minItems" : 1, + "maxItems" : 4, + "items" : { + "$ref" : "#/components/schemas/MediaId" + } + }, + "tagged_user_ids" : { + "type" : "array", + "description" : "A list of User Ids to be tagged in the media for created Tweet.", + "minItems" : 0, + "maxItems" : 10, + "items" : { "$ref" : "#/components/schemas/UserId" - }, - "id" : { - "$ref" : "#/components/schemas/TweetId" } } }, - "withheld_in_countries" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/CountryCode" + "additionalProperties" : false + }, + "nullcast" : { + "type" : "boolean", + "description" : "Nullcasted (promoted-only) Posts do not appear in the public timeline and are not served to followers.", + "default" : false + }, + "poll" : { + "type" : "object", + "description" : "Poll options for a Tweet with a poll. This is mutually exclusive from Media, Quote Tweet Id, and Card URI.", + "required" : [ + "options", + "duration_minutes" + ], + "properties" : { + "duration_minutes" : { + "type" : "integer", + "description" : "Duration of the poll in minutes.", + "minimum" : 5, + "maximum" : 10080, + "format" : "int32" + }, + "options" : { + "type" : "array", + "minItems" : 2, + "maxItems" : 4, + "items" : { + "type" : "string", + "description" : "The text of a poll choice.", + "minLength" : 1, + "maxLength" : 25 + } + }, + "reply_settings" : { + "type" : "string", + "description" : "Settings to indicate who can reply to the Tweet.", + "enum" : [ + "following", + "mentionedUsers" + ] } - } - } - }, - "TweetText" : { - "type" : "string", - "description" : "The content of the Tweet.", - "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" - }, - "TweetUndropComplianceSchema" : { - "type" : "object", - "required" : [ - "undrop" - ], - "properties" : { - "undrop" : { - "$ref" : "#/components/schemas/TweetComplianceSchema" - } - } - }, - "TweetUnviewable" : { - "type" : "object", - "required" : [ - "tweet", - "event_at", - "application" - ], - "properties" : { - "application" : { - "type" : "string", - "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", - "example" : "apply" - }, - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" }, - "tweet" : { - "type" : "object", - "required" : [ - "id", - "author_id" - ], - "properties" : { - "author_id" : { + "additionalProperties" : false + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "reply" : { + "type" : "object", + "description" : "Tweet information of the Tweet being replied to.", + "required" : [ + "in_reply_to_tweet_id" + ], + "properties" : { + "exclude_reply_user_ids" : { + "type" : "array", + "description" : "A list of User Ids to be excluded from the reply Tweet.", + "items" : { "$ref" : "#/components/schemas/UserId" - }, - "id" : { - "$ref" : "#/components/schemas/TweetId" } + }, + "in_reply_to_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" } - } + }, + "additionalProperties" : false + }, + "reply_settings" : { + "type" : "string", + "description" : "Settings to indicate who can reply to the Tweet.", + "enum" : [ + "following", + "mentionedUsers", + "subscribers" + ] + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" } }, - "TweetUnviewableSchema" : { - "type" : "object", - "required" : [ - "public_tweet_unviewable" - ], - "properties" : { - "public_tweet_unviewable" : { - "$ref" : "#/components/schemas/TweetUnviewable" + "additionalProperties" : false + }, + "TweetCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "id", + "text" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "text" : { + "$ref" : "#/components/schemas/TweetText" + } + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "TweetWithheld" : { - "type" : "object", - "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", - "required" : [ - "copyright", - "country_codes" - ], - "properties" : { - "copyright" : { - "type" : "boolean", - "description" : "Indicates if the content is being withheld for on the basis of copyright infringement." - }, - "country_codes" : { - "type" : "array", - "description" : "Provides a list of countries where this content is not available.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "$ref" : "#/components/schemas/CountryCode" + } + }, + "TweetDeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "delete" + ], + "properties" : { + "delete" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "required" : [ + "deleted" + ], + "properties" : { + "deleted" : { + "type" : "boolean" } - }, - "scope" : { - "type" : "string", - "description" : "Indicates whether the content being withheld is the `tweet` or a `user`.", - "enum" : [ - "tweet", - "user" - ] + } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "TweetWithheldComplianceSchema" : { - "type" : "object", - "required" : [ - "withheld" - ], - "properties" : { - "withheld" : { - "$ref" : "#/components/schemas/TweetTakedownComplianceSchema" + } + }, + "TweetDropComplianceSchema" : { + "type" : "object", + "required" : [ + "drop" + ], + "properties" : { + "drop" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetEditComplianceObjectSchema" : { + "type" : "object", + "required" : [ + "tweet", + "event_at", + "initial_tweet_id", + "edit_tweet_ids" + ], + "properties" : { + "edit_tweet_ids" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/TweetId" + } + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "initial_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + } } } - }, - "UnlikeComplianceSchema" : { - "type" : "object", - "required" : [ - "favorite", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "favorite" : { - "type" : "object", - "required" : [ - "id", - "user_id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "user_id" : { - "$ref" : "#/components/schemas/UserId" + } + }, + "TweetEditComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet_edit" + ], + "properties" : { + "tweet_edit" : { + "$ref" : "#/components/schemas/TweetEditComplianceObjectSchema" + } + } + }, + "TweetHideRequest" : { + "type" : "object", + "required" : [ + "hidden" + ], + "properties" : { + "hidden" : { + "type" : "boolean" + } + } + }, + "TweetHideResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "hidden" : { + "type" : "boolean" + } + } + } + } + }, + "TweetId" : { + "type" : "string", + "description" : "Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", + "pattern" : "^[0-9]{1,19}$", + "example" : "1346889436626259968" + }, + "TweetLabelData" : { + "description" : "Tweet label data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/TweetNoticeSchema" + }, + { + "$ref" : "#/components/schemas/TweetUnviewableSchema" + } + ] + }, + "TweetLabelStreamResponse" : { + "description" : "Tweet label stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "Tweet Label event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/TweetLabelData" + } + } + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "UnsupportedAuthenticationProblem" : { - "description" : "A problem that indicates that the authentication used is not supported.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" + ] + }, + "TweetNotice" : { + "type" : "object", + "required" : [ + "tweet", + "event_type", + "event_at", + "application" + ], + "properties" : { + "application" : { + "type" : "string", + "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", + "example" : "apply" + }, + "details" : { + "type" : "string", + "description" : "Information shown on the Tweet label" + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "event_type" : { + "type" : "string", + "description" : "The type of label on the Tweet", + "example" : "misleading" + }, + "extended_details_url" : { + "type" : "string", + "description" : "Link to more information about this kind of label" + }, + "label_title" : { + "type" : "string", + "description" : "Title/header of the Tweet label" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } } - ] - }, - "UploadExpiration" : { - "type" : "string", - "description" : "Expiration time of the upload URL.", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "UploadUrl" : { - "type" : "string", - "description" : "URL to which the user will upload their Tweet or user IDs.", - "format" : "uri" - }, - "Url" : { - "type" : "string", - "description" : "A validly formatted URL.", - "format" : "uri", - "example" : "https://developer.twitter.com/en/docs/twitter-api" - }, - "UrlEntity" : { - "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" - }, - { - "$ref" : "#/components/schemas/UrlFields" + } + } + }, + "TweetNoticeSchema" : { + "type" : "object", + "required" : [ + "public_tweet_notice" + ], + "properties" : { + "public_tweet_notice" : { + "$ref" : "#/components/schemas/TweetNotice" + } + } + }, + "TweetTakedownComplianceSchema" : { + "type" : "object", + "required" : [ + "tweet", + "withheld_in_countries", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "quote_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" + } } - ] - }, - "UrlEntityDm" : { - "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", - "allOf" : [ - { - "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" - }, - { - "$ref" : "#/components/schemas/UrlFields" + }, + "withheld_in_countries" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CountryCode" } - ] - }, - "UrlFields" : { - "type" : "object", - "description" : "Represent the portion of text recognized as a URL.", - "required" : [ - "url" - ], - "properties" : { - "description" : { - "type" : "string", - "description" : "Description of the URL landing page.", - "example" : "This is a description of the website." - }, - "display_url" : { - "type" : "string", - "description" : "The URL as displayed in the X client.", - "example" : "twittercommunity.com/t/introducing-…" - }, - "expanded_url" : { - "$ref" : "#/components/schemas/Url" - }, - "images" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UrlImage" + } + } + }, + "TweetText" : { + "type" : "string", + "description" : "The content of the Tweet.", + "example" : "Learn how to use the user Tweet timeline and user mention timeline endpoints in the X API v2 to explore Tweet\\u2026 https:\\/\\/t.co\\/56a0vZUx7i" + }, + "TweetUndropComplianceSchema" : { + "type" : "object", + "required" : [ + "undrop" + ], + "properties" : { + "undrop" : { + "$ref" : "#/components/schemas/TweetComplianceSchema" + } + } + }, + "TweetUnviewable" : { + "type" : "object", + "required" : [ + "tweet", + "event_at", + "application" + ], + "properties" : { + "application" : { + "type" : "string", + "description" : "If the label is being applied or removed. Possible values are ‘apply’ or ‘remove’.", + "example" : "apply" + }, + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "tweet" : { + "type" : "object", + "required" : [ + "id", + "author_id" + ], + "properties" : { + "author_id" : { + "$ref" : "#/components/schemas/UserId" + }, + "id" : { + "$ref" : "#/components/schemas/TweetId" } - }, - "media_key" : { - "$ref" : "#/components/schemas/MediaKey" - }, - "status" : { - "$ref" : "#/components/schemas/HttpStatusCode" - }, - "title" : { - "type" : "string", - "description" : "Title of the page the URL points to.", - "example" : "Introducing the v2 follow lookup endpoints" - }, - "unwound_url" : { - "type" : "string", - "description" : "Fully resolved url.", - "format" : "uri", - "example" : "https://twittercommunity.com/t/introducing-the-v2-follow-lookup-endpoints/147118" - }, - "url" : { - "$ref" : "#/components/schemas/Url" } } - }, - "UrlImage" : { - "type" : "object", - "description" : "Represent the information for the URL image.", - "properties" : { - "height" : { - "$ref" : "#/components/schemas/MediaHeight" - }, - "url" : { - "$ref" : "#/components/schemas/Url" - }, - "width" : { - "$ref" : "#/components/schemas/MediaWidth" + } + }, + "TweetUnviewableSchema" : { + "type" : "object", + "required" : [ + "public_tweet_unviewable" + ], + "properties" : { + "public_tweet_unviewable" : { + "$ref" : "#/components/schemas/TweetUnviewable" + } + } + }, + "TweetWithheld" : { + "type" : "object", + "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", + "required" : [ + "copyright", + "country_codes" + ], + "properties" : { + "copyright" : { + "type" : "boolean", + "description" : "Indicates if the content is being withheld for on the basis of copyright infringement." + }, + "country_codes" : { + "type" : "array", + "description" : "Provides a list of countries where this content is not available.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "$ref" : "#/components/schemas/CountryCode" } + }, + "scope" : { + "type" : "string", + "description" : "Indicates whether the content being withheld is the `tweet` or a `user`.", + "enum" : [ + "tweet", + "user" + ] } - }, - "Usage" : { - "type" : "object", - "description" : "Usage per client app", - "properties" : { - "cap_reset_day" : { - "type" : "integer", - "description" : "Number of days left for the Tweet cap to reset", - "format" : "int32" - }, - "daily_client_app_usage" : { - "type" : "array", - "description" : "The daily usage breakdown for each Client Application a project", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/ClientAppUsage" - } - }, - "daily_project_usage" : { - "type" : "object", - "description" : "The daily usage breakdown for a project", - "properties" : { - "project_id" : { - "type" : "integer", - "description" : "The unique identifier for this project", - "format" : "int32" - }, - "usage" : { - "type" : "array", - "description" : "The usage value", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UsageFields" - } - } + } + }, + "TweetWithheldComplianceSchema" : { + "type" : "object", + "required" : [ + "withheld" + ], + "properties" : { + "withheld" : { + "$ref" : "#/components/schemas/TweetTakedownComplianceSchema" + } + } + }, + "UnlikeComplianceSchema" : { + "type" : "object", + "required" : [ + "favorite", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "favorite" : { + "type" : "object", + "required" : [ + "id", + "user_id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "user_id" : { + "$ref" : "#/components/schemas/UserId" } - }, - "project_cap" : { - "type" : "integer", - "description" : "Total number of Posts that can be read in this project per month", - "format" : "int32" - }, - "project_id" : { - "type" : "string", - "description" : "The unique identifier for this project", - "format" : "^[0-9]{1,19}$" - }, - "project_usage" : { - "type" : "integer", - "description" : "The number of Posts read in this project", - "format" : "int32" } } - }, - "UsageCapExceededProblem" : { - "description" : "A problem that indicates that a usage cap has been exceeded.", - "allOf" : [ - { - "$ref" : "#/components/schemas/Problem" - }, - { - "type" : "object", - "properties" : { - "period" : { - "type" : "string", - "enum" : [ - "Daily", - "Monthly" - ] - }, - "scope" : { - "type" : "string", - "enum" : [ - "Account", - "Product" - ] + } + }, + "UnsupportedAuthenticationProblem" : { + "description" : "A problem that indicates that the authentication used is not supported.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + } + ] + }, + "UploadExpiration" : { + "type" : "string", + "description" : "Expiration time of the upload URL.", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "UploadUrl" : { + "type" : "string", + "description" : "URL to which the user will upload their Tweet or user IDs.", + "format" : "uri" + }, + "Url" : { + "type" : "string", + "description" : "A validly formatted URL.", + "format" : "uri", + "example" : "https://developer.twitter.com/en/docs/twitter-api" + }, + "UrlEntity" : { + "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/UrlFields" + } + ] + }, + "UrlEntityDm" : { + "description" : "Represent the portion of text recognized as a URL, and its start and end position within the text.", + "allOf" : [ + { + "$ref" : "#/components/schemas/EntityIndicesInclusiveExclusive" + }, + { + "$ref" : "#/components/schemas/UrlFields" + } + ] + }, + "UrlFields" : { + "type" : "object", + "description" : "Represent the portion of text recognized as a URL.", + "required" : [ + "url" + ], + "properties" : { + "description" : { + "type" : "string", + "description" : "Description of the URL landing page.", + "example" : "This is a description of the website." + }, + "display_url" : { + "type" : "string", + "description" : "The URL as displayed in the X client.", + "example" : "twittercommunity.com/t/introducing-…" + }, + "expanded_url" : { + "$ref" : "#/components/schemas/Url" + }, + "images" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlImage" + } + }, + "media_key" : { + "$ref" : "#/components/schemas/MediaKey" + }, + "status" : { + "$ref" : "#/components/schemas/HttpStatusCode" + }, + "title" : { + "type" : "string", + "description" : "Title of the page the URL points to.", + "example" : "Introducing the v2 follow lookup endpoints" + }, + "unwound_url" : { + "type" : "string", + "description" : "Fully resolved url.", + "format" : "uri", + "example" : "https://twittercommunity.com/t/introducing-the-v2-follow-lookup-endpoints/147118" + }, + "url" : { + "$ref" : "#/components/schemas/Url" + } + } + }, + "UrlImage" : { + "type" : "object", + "description" : "Represent the information for the URL image.", + "properties" : { + "height" : { + "$ref" : "#/components/schemas/MediaHeight" + }, + "url" : { + "$ref" : "#/components/schemas/Url" + }, + "width" : { + "$ref" : "#/components/schemas/MediaWidth" + } + } + }, + "Usage" : { + "type" : "object", + "description" : "Usage per client app", + "properties" : { + "cap_reset_day" : { + "type" : "integer", + "description" : "Number of days left for the Tweet cap to reset", + "format" : "int32" + }, + "daily_client_app_usage" : { + "type" : "array", + "description" : "The daily usage breakdown for each Client Application a project", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/ClientAppUsage" + } + }, + "daily_project_usage" : { + "type" : "object", + "description" : "The daily usage breakdown for a project", + "properties" : { + "project_id" : { + "type" : "integer", + "description" : "The unique identifier for this project", + "format" : "int32" + }, + "usage" : { + "type" : "array", + "description" : "The usage value", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UsageFields" } } } - ] - }, - "UsageFields" : { - "type" : "object", - "description" : "Represents the data for Usage", - "properties" : { - "date" : { - "type" : "string", - "description" : "The time period for the usage", - "format" : "date-time", - "example" : "2021-01-06T18:40:40.000Z" - }, - "usage" : { - "type" : "integer", - "description" : "The usage value", - "format" : "int32" - } + }, + "project_cap" : { + "type" : "integer", + "description" : "Total number of Posts that can be read in this project per month", + "format" : "int32" + }, + "project_id" : { + "type" : "string", + "description" : "The unique identifier for this project", + "format" : "^[0-9]{1,19}$" + }, + "project_usage" : { + "type" : "integer", + "description" : "The number of Posts read in this project", + "format" : "int32" } - }, - "User" : { - "type" : "object", - "description" : "The X User object.", - "required" : [ - "id", - "name", - "username" - ], - "properties" : { - "connection_status" : { - "type" : "array", - "description" : "Returns detailed information about the relationship between two users.", - "minItems" : 0, - "items" : { + } + }, + "UsageCapExceededProblem" : { + "description" : "A problem that indicates that a usage cap has been exceeded.", + "allOf" : [ + { + "$ref" : "#/components/schemas/Problem" + }, + { + "type" : "object", + "properties" : { + "period" : { "type" : "string", - "description" : "Type of connection between users.", "enum" : [ - "follow_request_received", - "follow_request_sent", - "blocking", - "followed_by", - "following", - "muting" + "Daily", + "Monthly" + ] + }, + "scope" : { + "type" : "string", + "enum" : [ + "Account", + "Product" ] } - }, - "created_at" : { - "type" : "string", - "description" : "Creation time of this User.", - "format" : "date-time" - }, - "description" : { - "type" : "string", - "description" : "The text of this User's profile description (also known as bio), if the User provided one." - }, - "entities" : { - "type" : "object", - "description" : "A list of metadata found in the User's profile description.", - "properties" : { - "description" : { - "$ref" : "#/components/schemas/FullTextEntities" - }, - "url" : { - "type" : "object", - "description" : "Expanded details for the URL specified in the User's profile, with start and end indices.", - "properties" : { - "urls" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/UrlEntity" - } - } - } - } - } - }, - "id" : { - "$ref" : "#/components/schemas/UserId" - }, - "location" : { - "type" : "string", - "description" : "The location specified in the User's profile, if the User provided one. As this is a freeform value, it may not indicate a valid location, but it may be fuzzily evaluated when performing searches with location queries." - }, - "most_recent_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "name" : { - "type" : "string", - "description" : "The friendly name of this User, as shown on their profile." - }, - "pinned_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "profile_image_url" : { - "type" : "string", - "description" : "The URL to the profile image for this User.", - "format" : "uri" - }, - "protected" : { - "type" : "boolean", - "description" : "Indicates if this User has chosen to protect their Posts (in other words, if this User's Posts are private)." - }, - "public_metrics" : { - "type" : "object", - "description" : "A list of metrics for this User.", - "required" : [ - "followers_count", - "following_count", - "tweet_count", - "listed_count" - ], - "properties" : { - "followers_count" : { - "type" : "integer", - "description" : "Number of Users who are following this User." - }, - "following_count" : { - "type" : "integer", - "description" : "Number of Users this User is following." - }, - "like_count" : { - "type" : "integer", - "description" : "The number of likes created by this User." - }, - "listed_count" : { - "type" : "integer", - "description" : "The number of lists that include this User." - }, - "tweet_count" : { - "type" : "integer", - "description" : "The number of Posts (including Retweets) posted by this User." - } - } - }, - "receives_your_dm" : { - "type" : "boolean", - "description" : "Indicates if you can send a DM to this User" - }, - "subscription_type" : { - "type" : "string", - "description" : "The X Blue subscription type of the user, eg: Basic, Premium, PremiumPlus or None.", - "enum" : [ - "Basic", - "Premium", - "PremiumPlus", - "None" - ] - }, - "url" : { - "type" : "string", - "description" : "The URL specified in the User's profile." - }, - "username" : { - "$ref" : "#/components/schemas/UserName" - }, - "verified" : { - "type" : "boolean", - "description" : "Indicate if this User is a verified X User." - }, - "verified_type" : { + } + } + ] + }, + "UsageFields" : { + "type" : "object", + "description" : "Represents the data for Usage", + "properties" : { + "date" : { + "type" : "string", + "description" : "The time period for the usage", + "format" : "date-time", + "example" : "2021-01-06T18:40:40.000Z" + }, + "usage" : { + "type" : "integer", + "description" : "The usage value", + "format" : "int32" + } + } + }, + "User" : { + "type" : "object", + "description" : "The X User object.", + "required" : [ + "id", + "name", + "username" + ], + "properties" : { + "connection_status" : { + "type" : "array", + "description" : "Returns detailed information about the relationship between two users.", + "minItems" : 0, + "items" : { "type" : "string", - "description" : "The X Blue verified type of the user, eg: blue, government, business or none.", + "description" : "Type of connection between users.", "enum" : [ - "blue", - "government", - "business", - "none" + "follow_request_received", + "follow_request_sent", + "blocking", + "followed_by", + "following", + "muting" ] - }, - "withheld" : { - "$ref" : "#/components/schemas/UserWithheld" } }, - "example" : { - "created_at" : "2013-12-14T04:35:55Z", - "id" : "2244994945", - "name" : "X Dev", - "protected" : false, - "username" : "TwitterDev" - } - }, - "UserComplianceData" : { - "description" : "User compliance data.", - "oneOf" : [ - { - "$ref" : "#/components/schemas/UserProtectComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserUnprotectComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserDeleteComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserUndeleteComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserSuspendComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserUnsuspendComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserWithheldComplianceSchema" - }, - { - "$ref" : "#/components/schemas/UserScrubGeoSchema" - }, - { - "$ref" : "#/components/schemas/UserProfileModificationComplianceSchema" - } - ] - }, - "UserComplianceSchema" : { - "type" : "object", - "required" : [ - "user", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "user" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/UserId" - } - } - } - } - }, - "UserComplianceStreamResponse" : { - "description" : "User compliance stream events.", - "oneOf" : [ - { - "type" : "object", - "description" : "User compliance event.", - "required" : [ - "data" - ], - "properties" : { - "data" : { - "$ref" : "#/components/schemas/UserComplianceData" - } - } - }, - { - "type" : "object", - "required" : [ - "errors" - ], - "properties" : { - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + "created_at" : { + "type" : "string", + "description" : "Creation time of this User.", + "format" : "date-time" + }, + "description" : { + "type" : "string", + "description" : "The text of this User's profile description (also known as bio), if the User provided one." + }, + "entities" : { + "type" : "object", + "description" : "A list of metadata found in the User's profile description.", + "properties" : { + "description" : { + "$ref" : "#/components/schemas/FullTextEntities" + }, + "url" : { + "type" : "object", + "description" : "Expanded details for the URL specified in the User's profile, with start and end indices.", + "properties" : { + "urls" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/UrlEntity" + } } } } } - ] - }, - "UserDeleteComplianceSchema" : { - "type" : "object", - "required" : [ - "user_delete" - ], - "properties" : { - "user_delete" : { - "$ref" : "#/components/schemas/UserComplianceSchema" + }, + "id" : { + "$ref" : "#/components/schemas/UserId" + }, + "location" : { + "type" : "string", + "description" : "The location specified in the User's profile, if the User provided one. As this is a freeform value, it may not indicate a valid location, but it may be fuzzily evaluated when performing searches with location queries." + }, + "most_recent_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "name" : { + "type" : "string", + "description" : "The friendly name of this User, as shown on their profile." + }, + "pinned_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "profile_image_url" : { + "type" : "string", + "description" : "The URL to the profile image for this User.", + "format" : "uri" + }, + "protected" : { + "type" : "boolean", + "description" : "Indicates if this User has chosen to protect their Posts (in other words, if this User's Posts are private)." + }, + "public_metrics" : { + "type" : "object", + "description" : "A list of metrics for this User.", + "required" : [ + "followers_count", + "following_count", + "tweet_count", + "listed_count" + ], + "properties" : { + "followers_count" : { + "type" : "integer", + "description" : "Number of Users who are following this User." + }, + "following_count" : { + "type" : "integer", + "description" : "Number of Users this User is following." + }, + "like_count" : { + "type" : "integer", + "description" : "The number of likes created by this User." + }, + "listed_count" : { + "type" : "integer", + "description" : "The number of lists that include this User." + }, + "tweet_count" : { + "type" : "integer", + "description" : "The number of Posts (including Retweets) posted by this User." + } } + }, + "receives_your_dm" : { + "type" : "boolean", + "description" : "Indicates if you can send a DM to this User" + }, + "subscription_type" : { + "type" : "string", + "description" : "The X Blue subscription type of the user, eg: Basic, Premium, PremiumPlus or None.", + "enum" : [ + "Basic", + "Premium", + "PremiumPlus", + "None" + ] + }, + "url" : { + "type" : "string", + "description" : "The URL specified in the User's profile." + }, + "username" : { + "$ref" : "#/components/schemas/UserName" + }, + "verified" : { + "type" : "boolean", + "description" : "Indicate if this User is a verified X User." + }, + "verified_type" : { + "type" : "string", + "description" : "The X Blue verified type of the user, eg: blue, government, business or none.", + "enum" : [ + "blue", + "government", + "business", + "none" + ] + }, + "withheld" : { + "$ref" : "#/components/schemas/UserWithheld" } }, - "UserId" : { - "type" : "string", - "description" : "Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", - "pattern" : "^[0-9]{1,19}$", - "example" : "2244994945" - }, - "UserIdMatchesAuthenticatedUser" : { - "type" : "string", - "description" : "Unique identifier of this User. The value must be the same as the authenticated user.", - "example" : "2244994945" - }, - "UserName" : { - "type" : "string", - "description" : "The X handle (screen name) of this user.", - "pattern" : "^[A-Za-z0-9_]{1,15}$" - }, - "UserProfileModificationComplianceSchema" : { - "type" : "object", - "required" : [ - "user_profile_modification" - ], - "properties" : { - "user_profile_modification" : { - "$ref" : "#/components/schemas/UserProfileModificationObjectSchema" - } + "example" : { + "created_at" : "2013-12-14T04:35:55Z", + "id" : "2244994945", + "name" : "X Dev", + "protected" : false, + "username" : "TwitterDev" + } + }, + "UserComplianceData" : { + "description" : "User compliance data.", + "oneOf" : [ + { + "$ref" : "#/components/schemas/UserProtectComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUnprotectComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserDeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUndeleteComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserSuspendComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserUnsuspendComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserWithheldComplianceSchema" + }, + { + "$ref" : "#/components/schemas/UserScrubGeoSchema" + }, + { + "$ref" : "#/components/schemas/UserProfileModificationComplianceSchema" } - }, - "UserProfileModificationObjectSchema" : { - "type" : "object", - "required" : [ - "user", - "profile_field", - "new_value", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "new_value" : { - "type" : "string" - }, - "profile_field" : { - "type" : "string" - }, - "user" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/UserId" - } + ] + }, + "UserComplianceSchema" : { + "type" : "object", + "required" : [ + "user", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" } } } - }, - "UserProtectComplianceSchema" : { - "type" : "object", - "required" : [ - "user_protect" - ], - "properties" : { - "user_protect" : { - "$ref" : "#/components/schemas/UserComplianceSchema" + } + }, + "UserComplianceStreamResponse" : { + "description" : "User compliance stream events.", + "oneOf" : [ + { + "type" : "object", + "description" : "User compliance event.", + "required" : [ + "data" + ], + "properties" : { + "data" : { + "$ref" : "#/components/schemas/UserComplianceData" + } } - } - }, - "UserScrubGeoObjectSchema" : { - "type" : "object", - "required" : [ - "user", - "up_to_tweet_id", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "up_to_tweet_id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "user" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/UserId" + }, + { + "type" : "object", + "required" : [ + "errors" + ], + "properties" : { + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } } } - }, - "UserScrubGeoSchema" : { - "type" : "object", - "required" : [ - "scrub_geo" - ], - "properties" : { - "scrub_geo" : { - "$ref" : "#/components/schemas/UserScrubGeoObjectSchema" - } + ] + }, + "UserDeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "user_delete" + ], + "properties" : { + "user_delete" : { + "$ref" : "#/components/schemas/UserComplianceSchema" } - }, - "UserSearchQuery" : { - "type" : "string", - "description" : "The the search string by which to query for users.", - "pattern" : "^[A-Za-z0-9_]{1,32}$" - }, - "UserSuspendComplianceSchema" : { - "type" : "object", - "required" : [ - "user_suspend" - ], - "properties" : { - "user_suspend" : { - "$ref" : "#/components/schemas/UserComplianceSchema" - } + } + }, + "UserId" : { + "type" : "string", + "description" : "Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.", + "pattern" : "^[0-9]{1,19}$", + "example" : "2244994945" + }, + "UserIdMatchesAuthenticatedUser" : { + "type" : "string", + "description" : "Unique identifier of this User. The value must be the same as the authenticated user.", + "example" : "2244994945" + }, + "UserName" : { + "type" : "string", + "description" : "The X handle (screen name) of this user.", + "pattern" : "^[A-Za-z0-9_]{1,15}$" + }, + "UserProfileModificationComplianceSchema" : { + "type" : "object", + "required" : [ + "user_profile_modification" + ], + "properties" : { + "user_profile_modification" : { + "$ref" : "#/components/schemas/UserProfileModificationObjectSchema" } - }, - "UserTakedownComplianceSchema" : { - "type" : "object", - "required" : [ - "user", - "withheld_in_countries", - "event_at" - ], - "properties" : { - "event_at" : { - "type" : "string", - "description" : "Event time.", - "format" : "date-time", - "example" : "2021-07-06T18:40:40.000Z" - }, - "user" : { - "type" : "object", - "required" : [ - "id" - ], - "properties" : { - "id" : { - "$ref" : "#/components/schemas/UserId" - } - } - }, - "withheld_in_countries" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/CountryCode" + } + }, + "UserProfileModificationObjectSchema" : { + "type" : "object", + "required" : [ + "user", + "profile_field", + "new_value", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "new_value" : { + "type" : "string" + }, + "profile_field" : { + "type" : "string" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" } } } - }, - "UserUndeleteComplianceSchema" : { - "type" : "object", - "required" : [ - "user_undelete" - ], - "properties" : { - "user_undelete" : { - "$ref" : "#/components/schemas/UserComplianceSchema" - } + } + }, + "UserProtectComplianceSchema" : { + "type" : "object", + "required" : [ + "user_protect" + ], + "properties" : { + "user_protect" : { + "$ref" : "#/components/schemas/UserComplianceSchema" } - }, - "UserUnprotectComplianceSchema" : { - "type" : "object", - "required" : [ - "user_unprotect" - ], - "properties" : { - "user_unprotect" : { - "$ref" : "#/components/schemas/UserComplianceSchema" + } + }, + "UserScrubGeoObjectSchema" : { + "type" : "object", + "required" : [ + "user", + "up_to_tweet_id", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "up_to_tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" + } } } - }, - "UserUnsuspendComplianceSchema" : { - "type" : "object", - "required" : [ - "user_unsuspend" - ], - "properties" : { - "user_unsuspend" : { - "$ref" : "#/components/schemas/UserComplianceSchema" - } + } + }, + "UserScrubGeoSchema" : { + "type" : "object", + "required" : [ + "scrub_geo" + ], + "properties" : { + "scrub_geo" : { + "$ref" : "#/components/schemas/UserScrubGeoObjectSchema" } - }, - "UserWithheld" : { - "type" : "object", - "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", - "required" : [ - "country_codes" - ], - "properties" : { - "country_codes" : { - "type" : "array", - "description" : "Provides a list of countries where this content is not available.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "$ref" : "#/components/schemas/CountryCode" + } + }, + "UserSearchQuery" : { + "type" : "string", + "description" : "The the search string by which to query for users.", + "pattern" : "^[A-Za-z0-9_]{1,32}$" + }, + "UserSuspendComplianceSchema" : { + "type" : "object", + "required" : [ + "user_suspend" + ], + "properties" : { + "user_suspend" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserTakedownComplianceSchema" : { + "type" : "object", + "required" : [ + "user", + "withheld_in_countries", + "event_at" + ], + "properties" : { + "event_at" : { + "type" : "string", + "description" : "Event time.", + "format" : "date-time", + "example" : "2021-07-06T18:40:40.000Z" + }, + "user" : { + "type" : "object", + "required" : [ + "id" + ], + "properties" : { + "id" : { + "$ref" : "#/components/schemas/UserId" } - }, - "scope" : { - "type" : "string", - "description" : "Indicates that the content being withheld is a `user`.", - "enum" : [ - "user" - ] } - } - }, - "UserWithheldComplianceSchema" : { - "type" : "object", - "required" : [ - "user_withheld" - ], - "properties" : { - "user_withheld" : { - "$ref" : "#/components/schemas/UserTakedownComplianceSchema" + }, + "withheld_in_countries" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/CountryCode" } } - }, - "UsersFollowingCreateRequest" : { - "type" : "object", - "required" : [ - "target_user_id" - ], - "properties" : { - "target_user_id" : { - "$ref" : "#/components/schemas/UserId" + } + }, + "UserUndeleteComplianceSchema" : { + "type" : "object", + "required" : [ + "user_undelete" + ], + "properties" : { + "user_undelete" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserUnprotectComplianceSchema" : { + "type" : "object", + "required" : [ + "user_unprotect" + ], + "properties" : { + "user_unprotect" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserUnsuspendComplianceSchema" : { + "type" : "object", + "required" : [ + "user_unsuspend" + ], + "properties" : { + "user_unsuspend" : { + "$ref" : "#/components/schemas/UserComplianceSchema" + } + } + }, + "UserWithheld" : { + "type" : "object", + "description" : "Indicates withholding details for [withheld content](https://help.twitter.com/en/rules-and-policies/tweet-withheld-by-country).", + "required" : [ + "country_codes" + ], + "properties" : { + "country_codes" : { + "type" : "array", + "description" : "Provides a list of countries where this content is not available.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "$ref" : "#/components/schemas/CountryCode" } + }, + "scope" : { + "type" : "string", + "description" : "Indicates that the content being withheld is a `user`.", + "enum" : [ + "user" + ] } - }, - "UsersFollowingCreateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "following" : { - "type" : "boolean" - }, - "pending_follow" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "UserWithheldComplianceSchema" : { + "type" : "object", + "required" : [ + "user_withheld" + ], + "properties" : { + "user_withheld" : { + "$ref" : "#/components/schemas/UserTakedownComplianceSchema" + } + } + }, + "UsersFollowingCreateRequest" : { + "type" : "object", + "required" : [ + "target_user_id" + ], + "properties" : { + "target_user_id" : { + "$ref" : "#/components/schemas/UserId" + } + } + }, + "UsersFollowingCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" + }, + "pending_follow" : { + "type" : "boolean" } } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } } - }, - "UsersFollowingDeleteResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "following" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "UsersFollowingDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "following" : { + "type" : "boolean" } } - } - }, - "UsersLikesCreateRequest" : { - "type" : "object", - "required" : [ - "tweet_id" - ], - "properties" : { - "tweet_id" : { - "$ref" : "#/components/schemas/TweetId" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "UsersLikesCreateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "liked" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "UsersLikesCreateRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" + } + } + }, + "UsersLikesCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "liked" : { + "type" : "boolean" } } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } } - }, - "UsersLikesDeleteResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "liked" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "UsersLikesDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "liked" : { + "type" : "boolean" } } + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" + } + } + } + }, + "UsersRetweetsCreateRequest" : { + "type" : "object", + "required" : [ + "tweet_id" + ], + "properties" : { + "tweet_id" : { + "$ref" : "#/components/schemas/TweetId" } }, - "UsersRetweetsCreateRequest" : { - "type" : "object", - "required" : [ - "tweet_id" - ], - "properties" : { - "tweet_id" : { - "$ref" : "#/components/schemas/TweetId" + "additionalProperties" : false + }, + "UsersRetweetsCreateResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "id" : { + "$ref" : "#/components/schemas/TweetId" + }, + "retweeted" : { + "type" : "boolean" + } } }, - "additionalProperties" : false - }, - "UsersRetweetsCreateResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "id" : { - "$ref" : "#/components/schemas/TweetId" - }, - "retweeted" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" - } + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "UsersRetweetsDeleteResponse" : { - "type" : "object", - "properties" : { - "data" : { - "type" : "object", - "properties" : { - "retweeted" : { - "type" : "boolean" - } - } - }, - "errors" : { - "type" : "array", - "minItems" : 1, - "items" : { - "$ref" : "#/components/schemas/Problem" + } + }, + "UsersRetweetsDeleteResponse" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "object", + "properties" : { + "retweeted" : { + "type" : "boolean" } } - } - }, - "Variant" : { - "type" : "object", - "properties" : { - "bit_rate" : { - "type" : "integer", - "description" : "The bit rate of the media." - }, - "content_type" : { - "type" : "string", - "description" : "The content type of the media." - }, - "url" : { - "type" : "string", - "description" : "The url to the media.", - "format" : "uri" + }, + "errors" : { + "type" : "array", + "minItems" : 1, + "items" : { + "$ref" : "#/components/schemas/Problem" } } - }, - "Variants" : { - "type" : "array", - "description" : "An array of all available variants of the media.", - "items" : { - "$ref" : "#/components/schemas/Variant" + } + }, + "Variant" : { + "type" : "object", + "properties" : { + "bit_rate" : { + "type" : "integer", + "description" : "The bit rate of the media." + }, + "content_type" : { + "type" : "string", + "description" : "The content type of the media." + }, + "url" : { + "type" : "string", + "description" : "The url to the media.", + "format" : "uri" } - }, - "Video" : { - "allOf" : [ - { - "$ref" : "#/components/schemas/Media" - }, - { - "type" : "object", - "properties" : { - "duration_ms" : { - "type" : "integer" - }, - "non_public_metrics" : { - "type" : "object", - "description" : "Nonpublic engagement metrics for the Media at the time of the request.", - "properties" : { - "playback_0_count" : { - "type" : "integer", - "description" : "Number of users who made it through 0% of the video.", - "format" : "int32" - }, - "playback_100_count" : { - "type" : "integer", - "description" : "Number of users who made it through 100% of the video.", - "format" : "int32" - }, - "playback_25_count" : { - "type" : "integer", - "description" : "Number of users who made it through 25% of the video.", - "format" : "int32" - }, - "playback_50_count" : { - "type" : "integer", - "description" : "Number of users who made it through 50% of the video.", - "format" : "int32" - }, - "playback_75_count" : { - "type" : "integer", - "description" : "Number of users who made it through 75% of the video.", - "format" : "int32" - } + } + }, + "Variants" : { + "type" : "array", + "description" : "An array of all available variants of the media.", + "items" : { + "$ref" : "#/components/schemas/Variant" + } + }, + "Video" : { + "allOf" : [ + { + "$ref" : "#/components/schemas/Media" + }, + { + "type" : "object", + "properties" : { + "duration_ms" : { + "type" : "integer" + }, + "non_public_metrics" : { + "type" : "object", + "description" : "Nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" } - }, - "organic_metrics" : { - "type" : "object", - "description" : "Organic nonpublic engagement metrics for the Media at the time of the request.", - "properties" : { - "playback_0_count" : { - "type" : "integer", - "description" : "Number of users who made it through 0% of the video.", - "format" : "int32" - }, - "playback_100_count" : { - "type" : "integer", - "description" : "Number of users who made it through 100% of the video.", - "format" : "int32" - }, - "playback_25_count" : { - "type" : "integer", - "description" : "Number of users who made it through 25% of the video.", - "format" : "int32" - }, - "playback_50_count" : { - "type" : "integer", - "description" : "Number of users who made it through 50% of the video.", - "format" : "int32" - }, - "playback_75_count" : { - "type" : "integer", - "description" : "Number of users who made it through 75% of the video.", - "format" : "int32" - }, - "view_count" : { - "type" : "integer", - "description" : "Number of times this video has been viewed.", - "format" : "int32" - } + } + }, + "organic_metrics" : { + "type" : "object", + "description" : "Organic nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" + }, + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" } - }, - "preview_image_url" : { - "type" : "string", - "format" : "uri" - }, - "promoted_metrics" : { - "type" : "object", - "description" : "Promoted nonpublic engagement metrics for the Media at the time of the request.", - "properties" : { - "playback_0_count" : { - "type" : "integer", - "description" : "Number of users who made it through 0% of the video.", - "format" : "int32" - }, - "playback_100_count" : { - "type" : "integer", - "description" : "Number of users who made it through 100% of the video.", - "format" : "int32" - }, - "playback_25_count" : { - "type" : "integer", - "description" : "Number of users who made it through 25% of the video.", - "format" : "int32" - }, - "playback_50_count" : { - "type" : "integer", - "description" : "Number of users who made it through 50% of the video.", - "format" : "int32" - }, - "playback_75_count" : { - "type" : "integer", - "description" : "Number of users who made it through 75% of the video.", - "format" : "int32" - }, - "view_count" : { - "type" : "integer", - "description" : "Number of times this video has been viewed.", - "format" : "int32" - } + } + }, + "preview_image_url" : { + "type" : "string", + "format" : "uri" + }, + "promoted_metrics" : { + "type" : "object", + "description" : "Promoted nonpublic engagement metrics for the Media at the time of the request.", + "properties" : { + "playback_0_count" : { + "type" : "integer", + "description" : "Number of users who made it through 0% of the video.", + "format" : "int32" + }, + "playback_100_count" : { + "type" : "integer", + "description" : "Number of users who made it through 100% of the video.", + "format" : "int32" + }, + "playback_25_count" : { + "type" : "integer", + "description" : "Number of users who made it through 25% of the video.", + "format" : "int32" + }, + "playback_50_count" : { + "type" : "integer", + "description" : "Number of users who made it through 50% of the video.", + "format" : "int32" + }, + "playback_75_count" : { + "type" : "integer", + "description" : "Number of users who made it through 75% of the video.", + "format" : "int32" + }, + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" } - }, - "public_metrics" : { - "type" : "object", - "description" : "Engagement metrics for the Media at the time of the request.", - "properties" : { - "view_count" : { - "type" : "integer", - "description" : "Number of times this video has been viewed.", - "format" : "int32" - } + } + }, + "public_metrics" : { + "type" : "object", + "description" : "Engagement metrics for the Media at the time of the request.", + "properties" : { + "view_count" : { + "type" : "integer", + "description" : "Number of times this video has been viewed.", + "format" : "int32" } - }, - "variants" : { - "$ref" : "#/components/schemas/Variants" } + }, + "variants" : { + "$ref" : "#/components/schemas/Variants" } } - ] - } - }, - "parameters" : { - "ComplianceJobFieldsParameter" : { - "name" : "compliance_job.fields", - "in" : "query", - "description" : "A comma separated list of ComplianceJob fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a ComplianceJob object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "created_at", - "download_expires_at", - "download_url", - "id", - "name", - "resumable", - "status", - "type", - "upload_expires_at", - "upload_url" - ] - }, - "example" : [ + } + ] + } + }, + "parameters" : { + "ComplianceJobFieldsParameter" : { + "name" : "compliance_job.fields", + "in" : "query", + "description" : "A comma separated list of ComplianceJob fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a ComplianceJob object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "created_at", "download_expires_at", "download_url", @@ -14679,86 +14666,86 @@ "upload_url" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "created_at", + "download_expires_at", + "download_url", + "id", + "name", + "resumable", + "status", + "type", + "upload_expires_at", + "upload_url" + ] }, - "DmConversationFieldsParameter" : { - "name" : "dm_conversation.fields", - "in" : "query", - "description" : "A comma separated list of DmConversation fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a DmConversation object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "id" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "DmConversationFieldsParameter" : { + "name" : "dm_conversation.fields", + "in" : "query", + "description" : "A comma separated list of DmConversation fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a DmConversation object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "id" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "id" + ] }, - "DmEventExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [DmEvent](#DmEvent) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "attachments.media_keys", - "participant_ids", - "referenced_tweets.id", - "sender_id" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "DmEventExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [DmEvent](#DmEvent) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "attachments.media_keys", "participant_ids", "referenced_tweets.id", "sender_id" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "attachments.media_keys", + "participant_ids", + "referenced_tweets.id", + "sender_id" + ] }, - "DmEventFieldsParameter" : { - "name" : "dm_event.fields", - "in" : "query", - "description" : "A comma separated list of DmEvent fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a DmEvent object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "attachments", - "created_at", - "dm_conversation_id", - "entities", - "event_type", - "id", - "participant_ids", - "referenced_tweets", - "sender_id", - "text" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "DmEventFieldsParameter" : { + "name" : "dm_event.fields", + "in" : "query", + "description" : "A comma separated list of DmEvent fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a DmEvent object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "attachments", "created_at", "dm_conversation_id", @@ -14771,106 +14758,108 @@ "text" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "attachments", + "created_at", + "dm_conversation_id", + "entities", + "event_type", + "id", + "participant_ids", + "referenced_tweets", + "sender_id", + "text" + ] }, - "LikeExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [Like](#Like) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "liked_tweet_id" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "LikeExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Like](#Like) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "liked_tweet_id" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "liked_tweet_id" + ] }, - "LikeFieldsParameter" : { - "name" : "like.fields", - "in" : "query", - "description" : "A comma separated list of Like fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Like object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "created_at", - "id", - "liked_tweet_id", - "timestamp_ms" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "LikeFieldsParameter" : { + "name" : "like.fields", + "in" : "query", + "description" : "A comma separated list of Like fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Like object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "created_at", "id", "liked_tweet_id", "timestamp_ms" - ] - }, - "explode" : false, - "style" : "form" - }, - "ListExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [List](#List) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "owner_id" - ] - }, - "example" : [ + ] + }, + "example" : [ + "created_at", + "id", + "liked_tweet_id", + "timestamp_ms" + ] + }, + "explode" : false, + "style" : "form" + }, + "ListExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [List](#List) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "owner_id" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "owner_id" + ] }, - "ListFieldsParameter" : { - "name" : "list.fields", - "in" : "query", - "description" : "A comma separated list of List fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a List object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "created_at", - "description", - "follower_count", - "id", - "member_count", - "name", - "owner_id", - "private" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "ListFieldsParameter" : { + "name" : "list.fields", + "in" : "query", + "description" : "A comma separated list of List fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a List object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "created_at", "description", "follower_count", @@ -14881,38 +14870,33 @@ "private" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "created_at", + "description", + "follower_count", + "id", + "member_count", + "name", + "owner_id", + "private" + ] }, - "MediaFieldsParameter" : { - "name" : "media.fields", - "in" : "query", - "description" : "A comma separated list of Media fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Media object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "alt_text", - "duration_ms", - "height", - "media_key", - "non_public_metrics", - "organic_metrics", - "preview_image_url", - "promoted_metrics", - "public_metrics", - "type", - "url", - "variants", - "width" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "MediaFieldsParameter" : { + "name" : "media.fields", + "in" : "query", + "description" : "A comma separated list of Media fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Media object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "alt_text", "duration_ms", "height", @@ -14928,33 +14912,38 @@ "width" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "alt_text", + "duration_ms", + "height", + "media_key", + "non_public_metrics", + "organic_metrics", + "preview_image_url", + "promoted_metrics", + "public_metrics", + "type", + "url", + "variants", + "width" + ] }, - "PlaceFieldsParameter" : { - "name" : "place.fields", - "in" : "query", - "description" : "A comma separated list of Place fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Place object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "contained_within", - "country", - "country_code", - "full_name", - "geo", - "id", - "name", - "place_type" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "PlaceFieldsParameter" : { + "name" : "place.fields", + "in" : "query", + "description" : "A comma separated list of Place fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Place object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "contained_within", "country", "country_code", @@ -14965,30 +14954,33 @@ "place_type" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "contained_within", + "country", + "country_code", + "full_name", + "geo", + "id", + "name", + "place_type" + ] }, - "PollFieldsParameter" : { - "name" : "poll.fields", - "in" : "query", - "description" : "A comma separated list of Poll fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Poll object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "duration_minutes", - "end_datetime", - "id", - "options", - "voting_status" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "PollFieldsParameter" : { + "name" : "poll.fields", + "in" : "query", + "description" : "A comma separated list of Poll fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Poll object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "duration_minutes", "end_datetime", "id", @@ -14996,30 +14988,30 @@ "voting_status" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "duration_minutes", + "end_datetime", + "id", + "options", + "voting_status" + ] }, - "RulesCountFieldsParameter" : { - "name" : "rules_count.fields", - "in" : "query", - "description" : "A comma separated list of RulesCount fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a RulesCount object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "all_project_client_apps", - "cap_per_client_app", - "cap_per_project", - "client_app_rules_count", - "project_rules_count" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "RulesCountFieldsParameter" : { + "name" : "rules_count.fields", + "in" : "query", + "description" : "A comma separated list of RulesCount fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a RulesCount object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "all_project_client_apps", "cap_per_client_app", "cap_per_project", @@ -15027,56 +15019,56 @@ "project_rules_count" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "all_project_client_apps", + "cap_per_client_app", + "cap_per_project", + "client_app_rules_count", + "project_rules_count" + ] }, - "SearchCountFieldsParameter" : { - "name" : "search_count.fields", - "in" : "query", - "description" : "A comma separated list of SearchCount fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a SearchCount object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "end", - "start", - "tweet_count" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "SearchCountFieldsParameter" : { + "name" : "search_count.fields", + "in" : "query", + "description" : "A comma separated list of SearchCount fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a SearchCount object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "end", "start", "tweet_count" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "end", + "start", + "tweet_count" + ] }, - "SpaceExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [Space](#Space) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "creator_id", - "host_ids", - "invited_user_ids", - "speaker_ids", - "topic_ids" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "SpaceExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Space](#Space) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "creator_id", "host_ids", "invited_user_ids", @@ -15084,42 +15076,30 @@ "topic_ids" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "creator_id", + "host_ids", + "invited_user_ids", + "speaker_ids", + "topic_ids" + ] }, - "SpaceFieldsParameter" : { - "name" : "space.fields", - "in" : "query", - "description" : "A comma separated list of Space fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Space object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "created_at", - "creator_id", - "ended_at", - "host_ids", - "id", - "invited_user_ids", - "is_ticketed", - "lang", - "participant_count", - "scheduled_start", - "speaker_ids", - "started_at", - "state", - "subscriber_count", - "title", - "topic_ids", - "updated_at" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "SpaceFieldsParameter" : { + "name" : "space.fields", + "in" : "query", + "description" : "A comma separated list of Space fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Space object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "created_at", "creator_id", "ended_at", @@ -15139,88 +15119,93 @@ "updated_at" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "created_at", + "creator_id", + "ended_at", + "host_ids", + "id", + "invited_user_ids", + "is_ticketed", + "lang", + "participant_count", + "scheduled_start", + "speaker_ids", + "started_at", + "state", + "subscriber_count", + "title", + "topic_ids", + "updated_at" + ] }, - "TopicFieldsParameter" : { - "name" : "topic.fields", - "in" : "query", - "description" : "A comma separated list of Topic fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Topic object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "description", - "id", - "name" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "TopicFieldsParameter" : { + "name" : "topic.fields", + "in" : "query", + "description" : "A comma separated list of Topic fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Topic object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "description", "id", "name" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "description", + "id", + "name" + ] }, - "TrendFieldsParameter" : { - "name" : "trend.fields", - "in" : "query", - "description" : "A comma separated list of Trend fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Trend object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "trend_name", - "tweet_count" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "TrendFieldsParameter" : { + "name" : "trend.fields", + "in" : "query", + "description" : "A comma separated list of Trend fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Trend object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "trend_name", "tweet_count" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "trend_name", + "tweet_count" + ] }, - "TweetExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [Tweet](#Tweet) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "attachments.media_keys", - "attachments.media_source_tweet", - "attachments.poll_ids", - "author_id", - "edit_history_tweet_ids", - "entities.mentions.username", - "geo.place_id", - "in_reply_to_user_id", - "entities.note.mentions.username", - "referenced_tweets.id", - "referenced_tweets.id.author_id", - "author_screen_name" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "TweetExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [Tweet](#Tweet) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "attachments.media_keys", "attachments.media_source_tweet", "attachments.poll_ids", @@ -15235,51 +15220,37 @@ "author_screen_name" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "attachments.media_keys", + "attachments.media_source_tweet", + "attachments.poll_ids", + "author_id", + "edit_history_tweet_ids", + "entities.mentions.username", + "geo.place_id", + "in_reply_to_user_id", + "entities.note.mentions.username", + "referenced_tweets.id", + "referenced_tweets.id.author_id", + "author_screen_name" + ] }, - "TweetFieldsParameter" : { - "name" : "tweet.fields", - "in" : "query", - "description" : "A comma separated list of Tweet fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Tweet object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "attachments", - "author_id", - "card_uri", - "context_annotations", - "conversation_id", - "created_at", - "edit_controls", - "edit_history_tweet_ids", - "entities", - "geo", - "id", - "in_reply_to_user_id", - "lang", - "non_public_metrics", - "note_tweet", - "organic_metrics", - "possibly_sensitive", - "promoted_metrics", - "public_metrics", - "referenced_tweets", - "reply_settings", - "scopes", - "source", - "text", - "username", - "withheld" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "TweetFieldsParameter" : { + "name" : "tweet.fields", + "in" : "query", + "description" : "A comma separated list of Tweet fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Tweet object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "attachments", "author_id", "card_uri", @@ -15308,31 +15279,51 @@ "withheld" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "attachments", + "author_id", + "card_uri", + "context_annotations", + "conversation_id", + "created_at", + "edit_controls", + "edit_history_tweet_ids", + "entities", + "geo", + "id", + "in_reply_to_user_id", + "lang", + "non_public_metrics", + "note_tweet", + "organic_metrics", + "possibly_sensitive", + "promoted_metrics", + "public_metrics", + "referenced_tweets", + "reply_settings", + "scopes", + "source", + "text", + "username", + "withheld" + ] }, - "UsageFieldsParameter" : { - "name" : "usage.fields", - "in" : "query", - "description" : "A comma separated list of Usage fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a Usage object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "cap_reset_day", - "daily_client_app_usage", - "daily_project_usage", - "project_cap", - "project_id", - "project_usage" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "UsageFieldsParameter" : { + "name" : "usage.fields", + "in" : "query", + "description" : "A comma separated list of Usage fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a Usage object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "cap_reset_day", "daily_client_app_usage", "daily_project_usage", @@ -15341,68 +15332,55 @@ "project_usage" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "cap_reset_day", + "daily_client_app_usage", + "daily_project_usage", + "project_cap", + "project_id", + "project_usage" + ] }, - "UserExpansionsParameter" : { - "name" : "expansions", - "in" : "query", - "description" : "A comma separated list of fields to expand.", - "schema" : { - "type" : "array", - "description" : "The list of fields you can expand for a [User](#User) object. If the field has an ID, it can be expanded into a full object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "most_recent_tweet_id", - "pinned_tweet_id" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "UserExpansionsParameter" : { + "name" : "expansions", + "in" : "query", + "description" : "A comma separated list of fields to expand.", + "schema" : { + "type" : "array", + "description" : "The list of fields you can expand for a [User](#User) object. If the field has an ID, it can be expanded into a full object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "most_recent_tweet_id", "pinned_tweet_id" ] }, - "explode" : false, - "style" : "form" + "example" : [ + "most_recent_tweet_id", + "pinned_tweet_id" + ] }, - "UserFieldsParameter" : { - "name" : "user.fields", - "in" : "query", - "description" : "A comma separated list of User fields to display.", - "required" : false, - "schema" : { - "type" : "array", - "description" : "The fields available for a User object.", - "minItems" : 1, - "uniqueItems" : true, - "items" : { - "type" : "string", - "enum" : [ - "connection_status", - "created_at", - "description", - "entities", - "id", - "location", - "most_recent_tweet_id", - "name", - "pinned_tweet_id", - "profile_image_url", - "protected", - "public_metrics", - "receives_your_dm", - "subscription_type", - "url", - "username", - "verified", - "verified_type", - "withheld" - ] - }, - "example" : [ + "explode" : false, + "style" : "form" + }, + "UserFieldsParameter" : { + "name" : "user.fields", + "in" : "query", + "description" : "A comma separated list of User fields to display.", + "required" : false, + "schema" : { + "type" : "array", + "description" : "The fields available for a User object.", + "minItems" : 1, + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "connection_status", "created_at", "description", @@ -15424,9 +15402,31 @@ "withheld" ] }, - "explode" : false, - "style" : "form" - } + "example" : [ + "connection_status", + "created_at", + "description", + "entities", + "id", + "location", + "most_recent_tweet_id", + "name", + "pinned_tweet_id", + "profile_image_url", + "protected", + "public_metrics", + "receives_your_dm", + "subscription_type", + "url", + "username", + "verified", + "verified_type", + "withheld" + ] + }, + "explode" : false, + "style" : "form" } } - } \ No newline at end of file + } +} \ No newline at end of file From e3d997c519b45274a3af6e519c05af419a8650d6 Mon Sep 17 00:00:00 2001 From: Visal Munasinghe <127712545+vish-mv@users.noreply.github.com> Date: Wed, 26 Jun 2024 15:49:40 +0530 Subject: [PATCH 09/10] Update Sanitations.md accoring to the sanitations made in oOpenApi specification --- docs/spec/sanitations.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/docs/spec/sanitations.md b/docs/spec/sanitations.md index 1e53ef9..ceda9d9 100644 --- a/docs/spec/sanitations.md +++ b/docs/spec/sanitations.md @@ -3,6 +3,27 @@ _Created_: 2024/03/26 \ _Updated_: 2024/03/26 \ _Edition_: Swan Lake +# Sanitation for OpenAPI specification + +This document records the sanitation done on top of the official OpenAPI specification from Twitter (X). The OpenAPI specification is obtained from the [Twitter OpenAPI Documentation](https://api.twitter.com/2/openapi.json/). These changes are implemented to enhance the overall usability and readability of the generated client. + +## Base URL Changes + +1. **Change the `url` property of the `servers` object**: + - **Original**: `https://api.twitter.com` + - **Updated**: `https://api.twitter.com/2` + - **Reason**: This change is made to ensure that all API paths are relative to the versioned base URL (`/2`), which improves the consistency and usability of the APIs. + +## Function Name Changes + +2. **Update API Paths**: + - **Original**: Paths included the version prefix in each endpoint (e.g., `/2/compliance/jobs`). + - **Updated**: Paths are modified to remove the version prefix from the endpoints, as it is now included in the base URL. For example: + - **Original**: `/2/compliance/jobs` + - **Updated**: `/compliance/jobs` + - **Reason**: This modification simplifies the API paths, making them shorter and more readable. It also centralizes the versioning to the base URL, which is a common best practice. + + ## OpenAPI cli command The following command was used to generate the Ballerina client from the OpenAPI specification. The command should be executed from the repository root directory. From 3c9efae751990efd5f5cf262adf7afac318e0743 Mon Sep 17 00:00:00 2001 From: Nipuna Ransinghe Date: Wed, 26 Jun 2024 19:18:22 +0530 Subject: [PATCH 10/10] Apply suggestions from code review --- docs/spec/sanitations.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/docs/spec/sanitations.md b/docs/spec/sanitations.md index ceda9d9..1cfcdb8 100644 --- a/docs/spec/sanitations.md +++ b/docs/spec/sanitations.md @@ -7,15 +7,11 @@ _Edition_: Swan Lake This document records the sanitation done on top of the official OpenAPI specification from Twitter (X). The OpenAPI specification is obtained from the [Twitter OpenAPI Documentation](https://api.twitter.com/2/openapi.json/). These changes are implemented to enhance the overall usability and readability of the generated client. -## Base URL Changes - 1. **Change the `url` property of the `servers` object**: - **Original**: `https://api.twitter.com` - **Updated**: `https://api.twitter.com/2` - **Reason**: This change is made to ensure that all API paths are relative to the versioned base URL (`/2`), which improves the consistency and usability of the APIs. -## Function Name Changes - 2. **Update API Paths**: - **Original**: Paths included the version prefix in each endpoint (e.g., `/2/compliance/jobs`). - **Updated**: Paths are modified to remove the version prefix from the endpoints, as it is now included in the base URL. For example: