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:
parent
162ad96a13
commit
28e49c7ddb
9 changed files with 90 additions and 199 deletions
|
|
@ -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"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue