1
Fork 0
mirror of https://github.com/thegeneralist01/twitter-openapi synced 2026-01-11 23:50:26 +01:00

fix error schema

Signed-off-by: ふぁ <yuki@yuki0311.com>
This commit is contained in:
ふぁ 2024-09-29 18:08:58 +09:00
parent 162ad96a13
commit 28e49c7ddb
No known key found for this signature in database
GPG key ID: 83A8A5E74872A8AA
9 changed files with 90 additions and 199 deletions

View file

@ -12,12 +12,14 @@ components:
- $ref: "#/components/schemas/Tweet"
- $ref: "#/components/schemas/TweetWithVisibilityResults"
- $ref: "#/components/schemas/TweetTombstone"
- $ref: "#/components/schemas/TweetUnavailable"
discriminator:
propertyName: __typename
mapping": # deprecated
Tweet: "#/components/schemas/Tweet"
TweetWithVisibilityResults: "#/components/schemas/TweetWithVisibilityResults"
TweetTombstone: "#/components/schemas/TweetTombstone"
TweetUnavailable: "#/components/schemas/TweetUnavailable"
TweetWithVisibilityResults:
required:
@ -138,6 +140,13 @@ components:
$ref: "./typename.yaml#/components/schemas/TypeName" # TweetWithVisibilityResults
additionalProperties: true # todo
TweetUnavailable: # nsfw tweet
properties:
__typename:
$ref: "./typename.yaml#/components/schemas/TypeName" # TweetUnavailable
reason:
type: string
Tweet:
required:
- "rest_id"