From f0e37687a49ada41b48268384980cd31f0c70d0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=B5=E3=81=81?= Date: Thu, 6 Jun 2024 11:52:47 +0900 Subject: [PATCH] update model MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: ふぁ --- dist/compatible/openapi-3.0.yaml | 81 ++++++++++++++--- .../compatible_discriminator/openapi-3.0.yaml | 81 ++++++++++++++--- dist/docs/openapi-3.0.yaml | 90 +++++++++++++++---- src/openapi/schemas/tweet.yaml | 57 +++++++++++- src/openapi/schemas/user.yaml | 20 +++++ 5 files changed, 289 insertions(+), 40 deletions(-) diff --git a/dist/compatible/openapi-3.0.yaml b/dist/compatible/openapi-3.0.yaml index afac807..9714a66 100644 --- a/dist/compatible/openapi-3.0.yaml +++ b/dist/compatible/openapi-3.0.yaml @@ -29,6 +29,12 @@ components: type: string required: - url + AllowDownloadStatus: + properties: + allow_download: + type: boolean + required: + - allow_download Article: properties: article_results: @@ -98,12 +104,28 @@ components: - original_img_width - original_img_url - color_info + ArticleLifecycleState: + properties: + modified_at_secs: + type: integer + required: + - modified_at_secs + ArticleMetadata: + properties: + first_published_at_secs: + type: integer + required: + - first_published_at_secs ArticleResult: properties: cover_media: $ref: '#/components/schemas/ArticleCoverMedia' id: type: string + lifecycle_state: + $ref: '#/components/schemas/ArticleLifecycleState' + metadata: + $ref: '#/components/schemas/ArticleMetadata' preview_text: type: string rest_id: @@ -117,6 +139,8 @@ components: - title - preview_text - cover_media + - metadata + - lifecycle_state ArticleResults: properties: result: @@ -955,8 +979,9 @@ components: Media: properties: additional_media_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -978,6 +1003,8 @@ components: type: array media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1003,8 +1030,7 @@ components: format: uri type: string video_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/MediaVideoInfo' required: - display_url - expanded_url @@ -1017,10 +1043,13 @@ components: - original_info - media_key - ext_media_availability + - media_results MediaExtended: properties: additional_media_info: $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -1044,6 +1073,8 @@ components: $ref: '#/components/schemas/MediaStats' media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1081,6 +1112,7 @@ components: - url - sizes - original_info + - media_results MediaOriginalInfo: properties: focus_rects: @@ -1110,6 +1142,18 @@ components: - w - h type: object + MediaResult: + properties: + media_key: + type: string + required: + - media_key + MediaResults: + properties: + result: + $ref: '#/components/schemas/MediaResult' + required: + - result MediaSize: properties: h: @@ -2566,6 +2610,8 @@ components: super_following: default: false type: boolean + tipjar_settings: + $ref: '#/components/schemas/UserTipJarSettings' user_seed_tweet_count: type: integer verification_info: @@ -2581,6 +2627,7 @@ components: - super_followed_by - super_following - profile_image_shape + - tipjar_settings UserFeatures: properties: mediatool_studio_library: @@ -2881,6 +2928,22 @@ components: properties: result: $ref: '#/components/schemas/UserUnion' + UserTipJarSettings: + properties: + bitcoin_handle: + type: string + cash_app_handle: + type: string + ethereum_handle: + type: string + gofundme_handle: + type: string + is_enabled: + type: boolean + patreon_handle: + type: string + venmo_handle: + type: string UserTweetsData: properties: user: @@ -5127,17 +5190,15 @@ paths: name: pathQueryId required: true schema: - default: eL8vHLgEw2ZL9X9dKdakLQ - example: eL8vHLgEw2ZL9X9dKdakLQ + default: GX5ovLTwyoN1Td13GHvhIg + example: GX5ovLTwyoN1Td13GHvhIg type: string - in: query name: variables required: true schema: - default: '{"count": 20, "includePromotedContent": true, "latestControlAvailable": - true}' - example: '{"count": 20, "includePromotedContent": true, "latestControlAvailable": - true}' + default: '{"listId": "1539453138322673664", "count": 20}' + example: '{"listId": "1539453138322673664", "count": 20}' type: string - in: query name: features diff --git a/dist/compatible_discriminator/openapi-3.0.yaml b/dist/compatible_discriminator/openapi-3.0.yaml index 7e4839e..682b8c1 100644 --- a/dist/compatible_discriminator/openapi-3.0.yaml +++ b/dist/compatible_discriminator/openapi-3.0.yaml @@ -29,6 +29,12 @@ components: type: string required: - url + AllowDownloadStatus: + properties: + allow_download: + type: boolean + required: + - allow_download Article: properties: article_results: @@ -98,12 +104,28 @@ components: - original_img_width - original_img_url - color_info + ArticleLifecycleState: + properties: + modified_at_secs: + type: integer + required: + - modified_at_secs + ArticleMetadata: + properties: + first_published_at_secs: + type: integer + required: + - first_published_at_secs ArticleResult: properties: cover_media: $ref: '#/components/schemas/ArticleCoverMedia' id: type: string + lifecycle_state: + $ref: '#/components/schemas/ArticleLifecycleState' + metadata: + $ref: '#/components/schemas/ArticleMetadata' preview_text: type: string rest_id: @@ -117,6 +139,8 @@ components: - title - preview_text - cover_media + - metadata + - lifecycle_state ArticleResults: properties: result: @@ -955,8 +979,9 @@ components: Media: properties: additional_media_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -978,6 +1003,8 @@ components: type: array media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1003,8 +1030,7 @@ components: format: uri type: string video_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/MediaVideoInfo' required: - display_url - expanded_url @@ -1017,10 +1043,13 @@ components: - original_info - media_key - ext_media_availability + - media_results MediaExtended: properties: additional_media_info: $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -1044,6 +1073,8 @@ components: $ref: '#/components/schemas/MediaStats' media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1081,6 +1112,7 @@ components: - url - sizes - original_info + - media_results MediaOriginalInfo: properties: focus_rects: @@ -1110,6 +1142,18 @@ components: - w - h type: object + MediaResult: + properties: + media_key: + type: string + required: + - media_key + MediaResults: + properties: + result: + $ref: '#/components/schemas/MediaResult' + required: + - result MediaSize: properties: h: @@ -2566,6 +2610,8 @@ components: super_following: default: false type: boolean + tipjar_settings: + $ref: '#/components/schemas/UserTipJarSettings' user_seed_tweet_count: type: integer verification_info: @@ -2581,6 +2627,7 @@ components: - super_followed_by - super_following - profile_image_shape + - tipjar_settings UserFeatures: properties: mediatool_studio_library: @@ -2881,6 +2928,22 @@ components: properties: result: $ref: '#/components/schemas/UserUnion' + UserTipJarSettings: + properties: + bitcoin_handle: + type: string + cash_app_handle: + type: string + ethereum_handle: + type: string + gofundme_handle: + type: string + is_enabled: + type: boolean + patreon_handle: + type: string + venmo_handle: + type: string UserTweetsData: properties: user: @@ -5101,17 +5164,15 @@ paths: name: pathQueryId required: true schema: - default: eL8vHLgEw2ZL9X9dKdakLQ - example: eL8vHLgEw2ZL9X9dKdakLQ + default: GX5ovLTwyoN1Td13GHvhIg + example: GX5ovLTwyoN1Td13GHvhIg type: string - in: query name: variables required: true schema: - default: '{"count": 20, "includePromotedContent": true, "latestControlAvailable": - true}' - example: '{"count": 20, "includePromotedContent": true, "latestControlAvailable": - true}' + default: '{"listId": "1539453138322673664", "count": 20}' + example: '{"listId": "1539453138322673664", "count": 20}' type: string - in: query name: features diff --git a/dist/docs/openapi-3.0.yaml b/dist/docs/openapi-3.0.yaml index 5b93cae..f7bbf97 100644 --- a/dist/docs/openapi-3.0.yaml +++ b/dist/docs/openapi-3.0.yaml @@ -29,6 +29,12 @@ components: type: string required: - url + AllowDownloadStatus: + properties: + allow_download: + type: boolean + required: + - allow_download Article: properties: article_results: @@ -98,12 +104,28 @@ components: - original_img_width - original_img_url - color_info + ArticleLifecycleState: + properties: + modified_at_secs: + type: integer + required: + - modified_at_secs + ArticleMetadata: + properties: + first_published_at_secs: + type: integer + required: + - first_published_at_secs ArticleResult: properties: cover_media: $ref: '#/components/schemas/ArticleCoverMedia' id: type: string + lifecycle_state: + $ref: '#/components/schemas/ArticleLifecycleState' + metadata: + $ref: '#/components/schemas/ArticleMetadata' preview_text: type: string rest_id: @@ -117,6 +139,8 @@ components: - title - preview_text - cover_media + - metadata + - lifecycle_state ArticleResults: properties: result: @@ -955,8 +979,9 @@ components: Media: properties: additional_media_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -978,6 +1003,8 @@ components: type: array media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1003,8 +1030,7 @@ components: format: uri type: string video_info: - additionalProperties: true - type: object + $ref: '#/components/schemas/MediaVideoInfo' required: - display_url - expanded_url @@ -1017,10 +1043,13 @@ components: - original_info - media_key - ext_media_availability + - media_results MediaExtended: properties: additional_media_info: $ref: '#/components/schemas/AdditionalMediaInfo' + allow_download_status: + $ref: '#/components/schemas/AllowDownloadStatus' display_url: format: uri type: string @@ -1044,6 +1073,8 @@ components: $ref: '#/components/schemas/MediaStats' media_key: type: string + media_results: + $ref: '#/components/schemas/MediaResults' media_url_https: format: uri type: string @@ -1081,6 +1112,7 @@ components: - url - sizes - original_info + - media_results MediaOriginalInfo: properties: focus_rects: @@ -1110,6 +1142,18 @@ components: - w - h type: object + MediaResult: + properties: + media_key: + type: string + required: + - media_key + MediaResults: + properties: + result: + $ref: '#/components/schemas/MediaResult' + required: + - result MediaSize: properties: h: @@ -2566,6 +2610,8 @@ components: super_following: default: false type: boolean + tipjar_settings: + $ref: '#/components/schemas/UserTipJarSettings' user_seed_tweet_count: type: integer verification_info: @@ -2581,6 +2627,7 @@ components: - super_followed_by - super_following - profile_image_shape + - tipjar_settings UserFeatures: properties: mediatool_studio_library: @@ -2881,6 +2928,22 @@ components: properties: result: $ref: '#/components/schemas/UserUnion' + UserTipJarSettings: + properties: + bitcoin_handle: + type: string + cash_app_handle: + type: string + ethereum_handle: + type: string + gofundme_handle: + type: string + is_enabled: + type: boolean + patreon_handle: + type: string + venmo_handle: + type: string UserTweetsData: properties: user: @@ -6002,8 +6065,8 @@ paths: name: pathQueryId required: true schema: - default: eL8vHLgEw2ZL9X9dKdakLQ - example: eL8vHLgEw2ZL9X9dKdakLQ + default: GX5ovLTwyoN1Td13GHvhIg + example: GX5ovLTwyoN1Td13GHvhIg type: string - content: application/json: @@ -6013,18 +6076,13 @@ paths: default: 20 example: 20 type: integer - includePromotedContent: - default: true - example: true - type: boolean - latestControlAvailable: - default: true - example: true - type: boolean + listId: + default: '1539453138322673664' + example: '1539453138322673664' + type: string required: + - listId - count - - includePromotedContent - - latestControlAvailable type: object in: query name: variables diff --git a/src/openapi/schemas/tweet.yaml b/src/openapi/schemas/tweet.yaml index 280cc1b..b3c121a 100644 --- a/src/openapi/schemas/tweet.yaml +++ b/src/openapi/schemas/tweet.yaml @@ -999,6 +999,7 @@ components: - "original_info" - "media_key" - "ext_media_availability" + - "media_results" properties: display_url: type: string @@ -1033,11 +1034,9 @@ components: ext_media_availability: $ref: "#/components/schemas/ExtMediaAvailability" video_info: - type: object - additionalProperties: true # todo + $ref: "#/components/schemas/MediaVideoInfo" additional_media_info: - type: object - additionalProperties: true # todo + $ref: "#/components/schemas/AdditionalMediaInfo" source_user_id_str: type: string pattern: "^[0-9]+$" @@ -1048,6 +1047,10 @@ components: type: string sensitive_media_warning: $ref: "#/components/schemas/SensitiveMediaWarning" + allow_download_status: + $ref: "#/components/schemas/AllowDownloadStatus" + media_results: + $ref: "#/components/schemas/MediaResults" TweetLegacyScopes: required: @@ -1095,6 +1098,7 @@ components: # - "features" - "sizes" - "original_info" + - "media_results" properties: display_url: type: string @@ -1144,6 +1148,10 @@ components: type: string sensitive_media_warning: $ref: "#/components/schemas/SensitiveMediaWarning" + allow_download_status: + $ref: "#/components/schemas/AllowDownloadStatus" + media_results: + $ref: "#/components/schemas/MediaResults" MediaOriginalInfo: required: @@ -1336,6 +1344,8 @@ components: - "title" - "preview_text" - "cover_media" + - "metadata" + - "lifecycle_state" properties: rest_id: type: string @@ -1348,6 +1358,10 @@ components: type: string cover_media: $ref: "#/components/schemas/ArticleCoverMedia" + metadata: + $ref: "#/components/schemas/ArticleMetadata" + lifecycle_state: + $ref: "#/components/schemas/ArticleLifecycleState" ArticleCoverMedia: required: @@ -1416,3 +1430,38 @@ components: type: integer red: type: integer + + ArticleMetadata: + required: + - "first_published_at_secs" + properties: + first_published_at_secs: + type: integer + + ArticleLifecycleState: + required: + - "modified_at_secs" + properties: + modified_at_secs: + type: integer + + AllowDownloadStatus: + required: + - "allow_download" + properties: + allow_download: + type: boolean + + MediaResults: + required: + - "result" + properties: + result: + $ref: "#/components/schemas/MediaResult" + + MediaResult: + required: + - "media_key" + properties: + media_key: + type: string diff --git a/src/openapi/schemas/user.yaml b/src/openapi/schemas/user.yaml index 89755af..e626c22 100644 --- a/src/openapi/schemas/user.yaml +++ b/src/openapi/schemas/user.yaml @@ -39,6 +39,7 @@ components: - "super_followed_by" - "super_following" - "profile_image_shape" + - "tipjar_settings" properties: __typename: @@ -92,6 +93,8 @@ components: $ref: "#/components/schemas/UserVerificationInfo" is_profile_translatable: type: boolean + tipjar_settings: + $ref: "#/components/schemas/UserTipJarSettings" UserProfessional: required: @@ -194,6 +197,23 @@ components: type: string enum: ["ExternalUrl"] + UserTipJarSettings: + properties: + is_enabled: + type: boolean + patreon_handle: + type: string + bitcoin_handle: + type: string + ethereum_handle: + type: string + cash_app_handle: + type: string + venmo_handle: + type: string + gofundme_handle: + type: string # uri + UserLegacy: required: - "blocked_by"