Skip to content

Commit

Permalink
doc: list/get token response is different from post
Browse files Browse the repository at this point in the history
  • Loading branch information
manics committed Apr 14, 2024
1 parent d0523f5 commit 0eac18b
Showing 1 changed file with 21 additions and 11 deletions.
32 changes: 21 additions & 11 deletions docs/source/_static/rest-api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -553,9 +553,12 @@ paths:
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/Token"
type: object
properties:
api_tokens:
type: array
items:
$ref: "#/components/schemas/Token"
401:
description: Authentication/Authorization error
content: {}
Expand Down Expand Up @@ -614,7 +617,7 @@ paths:
content:
application/json:
schema:
$ref: "#/components/schemas/Token"
$ref: "#/components/schemas/NewToken"
400:
description: Body must be a JSON dict or empty
content: {}
Expand All @@ -639,7 +642,7 @@ paths:
type: string
responses:
200:
description: The info for the new token
description: The info for the token
content:
application/json:
schema:
Expand Down Expand Up @@ -1930,12 +1933,7 @@ components:

Token:
type: object
properties:
token:
type: string
description:
The token itself. Only present in responses to requests for
a new token.
properties: &components-schemas-token-properties
id:
type: string
description:
Expand Down Expand Up @@ -1989,6 +1987,18 @@ components:
Only used for tokens set during oauth flows.
Added in 2.0.
NewToken:
type: object
properties:
<<:
- *components-schemas-token-properties
- token:
type: string
description:
The token itself. Only present in responses to requests for
a new token.

securitySchemes:
token:
type: http
Expand Down

0 comments on commit 0eac18b

Please sign in to comment.