From 8a7eba499fdc9db25fed0793bc1bafacbf63e34e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=B5=E3=81=81?= Date: Fri, 1 Sep 2023 13:58:16 +0900 Subject: [PATCH] enum value MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: ふぁ --- src/openapi/paths/other.yaml | 3 ++- src/openapi/schemas/content.yaml | 6 ++++-- src/openapi/schemas/tweet.yaml | 16 ++++++++++------ 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/src/openapi/paths/other.yaml b/src/openapi/paths/other.yaml index 280b3a8..de47a86 100644 --- a/src/openapi/paths/other.yaml +++ b/src/openapi/paths/other.yaml @@ -69,7 +69,8 @@ components: superFollowersCount: type: integer superFollowsApplicationStatus: - type: string # enum: NotStarted + type: string + enum: [NotStarted] user_id: type: string pattern: "^[0-9]+$" diff --git a/src/openapi/schemas/content.yaml b/src/openapi/schemas/content.yaml index 1d91d6d..913339f 100644 --- a/src/openapi/schemas/content.yaml +++ b/src/openapi/schemas/content.yaml @@ -60,7 +60,8 @@ components: entryType: $ref: "#/components/schemas/ContentEntryType" # TimelineTimelineCursor displayType: - type: string # enum + type: string + enum: [Vertical, VerticalConversation] items: type: array items: @@ -183,7 +184,8 @@ components: SocialContext: $ref: "#/components/schemas/SocialContext" userDisplayType: - type: string # enum + type: string + enum: [User, UserDetailed] user_results: $ref: "./user.yaml#/components/schemas/UserResults" diff --git a/src/openapi/schemas/tweet.yaml b/src/openapi/schemas/tweet.yaml index ba30666..e6ef176 100644 --- a/src/openapi/schemas/tweet.yaml +++ b/src/openapi/schemas/tweet.yaml @@ -102,7 +102,8 @@ components: type: string pattern: "^[0-9]+$" state: - type: string # enum + type: string + enum: [EnabledWithCount] TweetCard: properties: @@ -317,7 +318,8 @@ components: type: string format: uri type: - type: string # enum photo + type: string + enum: [photo] url: type: string format: uri @@ -371,7 +373,8 @@ components: type: string format: uri type: - type: string # enum # photo | video + type: string + enum: [photo, video, animated_gif] url: type: string format: uri @@ -469,7 +472,8 @@ components: - "status" properties: status: - type: string # enum Available + type: string + enum: [Available] MediaSizes: required: @@ -498,5 +502,5 @@ components: h: type: integer resize: - type: string # enum fit - + type: string + enum: [crop, fit]