From f2c4e0fa372e891839581d04dbf56a78742d03ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=B5=E3=81=81?= Date: Tue, 18 Apr 2023 02:21:04 +0900 Subject: [PATCH] fix type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: ふぁ --- openapi/openapi-3.0.yaml | 39 +++++++++++++++++++++++++++++---------- 1 file changed, 29 insertions(+), 10 deletions(-) diff --git a/openapi/openapi-3.0.yaml b/openapi/openapi-3.0.yaml index 2e96c33..551e350 100644 --- a/openapi/openapi-3.0.yaml +++ b/openapi/openapi-3.0.yaml @@ -587,20 +587,23 @@ components: required: - "user" properties: - home: + user: $ref: "#/components/schemas/UserTweetsUser" UserTweetsUser: required: - "result" properties: - tweets_timeline: + result: $ref: "#/components/schemas/UserTweetsResult" UserTweetsResult: required: + - "__typename" - "timeline_v2" properties: + __typename: + $ref: "#/components/schemas/TypeName" # User timeline_v2: $ref: "#/components/schemas/TimelineV2" @@ -624,20 +627,14 @@ components: TimelineV2: required: - - "__typename" - "timeline" properties: - __typename: - $ref: "#/components/schemas/TypeName" # User timeline: - type: array - items: - $ref: "#/components/schemas/Timeline" + $ref: "#/components/schemas/Timeline" Timeline: required: - "instructions" - - "metadata" properties: instructions: type: array @@ -654,15 +651,17 @@ components: oneOf: - $ref: "#/components/schemas/TimelineAddEntries" - $ref: "#/components/schemas/TimelineClearCache" + - $ref: "#/components/schemas/TimelinePinEntry" discriminator: propertyName: type mapping": # deprecated TimelineAddEntries: "#/components/schemas/TimelineAddEntries" TimelineClearCache: "#/components/schemas/TimelineClearCache" + TimelinePinEntry: "#/components/schemas/TimelinePinEntry" InstructionType: type: string - enum: [TimelineAddEntries] + enum: [TimelineAddEntries, TimelineClearCache, TimelinePinEntry] TimelineAddEntries: required: @@ -685,6 +684,17 @@ components: type: string $ref: "#/components/schemas/InstructionType" # TimelineClearCache + TimelinePinEntry: + required: + - type + - entry + properties: + type: + type: string + $ref: "#/components/schemas/InstructionType" # TimelinePinEntry + entry: + $ref: "#/components/schemas/TimelineAddEntry" + TimelineAddEntry: required: - "content" @@ -787,6 +797,15 @@ components: type: string tweet_results: $ref: "#/components/schemas/ItemResult" + socialContext: + type: object + properties: + contextType: + type: string # enum + text: + type: string + type: + type: string # enum ItemResult: required: