Skip to content

Commit

Permalink
fix: OpenAPI docs small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
dpgaspar committed May 3, 2022
1 parent 90130e4 commit a4756ba
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 10 deletions.
6 changes: 1 addition & 5 deletions superset/charts/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -516,14 +516,12 @@ def cache_screenshot(self, pk: int, **kwargs: Any) -> WerkzeugResponse:
schema:
$ref: '#/components/schemas/screenshot_query_schema'
responses:
200:
202:
description: Chart async result
content:
application/json:
schema:
$ref: "#/components/schemas/ChartCacheScreenshotResponseSchema"
302:
description: Redirects to the current digest
400:
$ref: '#/components/responses/400'
401:
Expand Down Expand Up @@ -596,8 +594,6 @@ def screenshot(self, pk: int, digest: str) -> WerkzeugResponse:
schema:
type: string
format: binary
302:
description: Redirects to the current digest
400:
$ref: '#/components/responses/400'
401:
Expand Down
2 changes: 2 additions & 0 deletions superset/dashboards/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -853,6 +853,8 @@ def thumbnail(self, pk: int, digest: str, **kwargs: Any) -> WerkzeugResponse:
properties:
message:
type: string
302:
description: Redirects to the current digest
401:
$ref: '#/components/responses/401'
404:
Expand Down
3 changes: 0 additions & 3 deletions superset/databases/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,6 @@ def post(self) -> Response:
type: number
result:
$ref: '#/components/schemas/{{self.__class__.__name__}}.post'
302:
description: Redirects to the current digest
400:
$ref: '#/components/responses/400'
401:
Expand Down Expand Up @@ -659,7 +657,6 @@ def related_objects(self, pk: int) -> Response:
schema:
type: integer
responses:
200:
200:
description: Query result
content:
Expand Down
2 changes: 2 additions & 0 deletions superset/embedded/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ def get(self, uuid: str) -> Response:
result:
$ref: '#/components/schemas/EmbeddedDashboardResponseSchema'
401:
$ref: '#/components/responses/401'
404:
$ref: '#/components/responses/404'
500:
$ref: '#/components/responses/500'
Expand Down
2 changes: 0 additions & 2 deletions superset/importexport/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,6 @@ def export(self) -> Response:
schema:
type: string
format: binary
400:
$ref: '#/components/responses/400'
401:
$ref: '#/components/responses/401'
404:
Expand Down
4 changes: 4 additions & 0 deletions superset/reports/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,8 @@ def post(self) -> Response:
$ref: '#/components/responses/401'
404:
$ref: '#/components/responses/404'
422:
$ref: '#/components/responses/422'
500:
$ref: '#/components/responses/500'
"""
Expand Down Expand Up @@ -379,6 +381,8 @@ def put(self, pk: int) -> Response:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
422:
$ref: '#/components/responses/422'
500:
$ref: '#/components/responses/500'
"""
Expand Down
2 changes: 2 additions & 0 deletions superset/security/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ def guest_token(self) -> Response:
type: string
401:
$ref: '#/components/responses/401'
400:
$ref: '#/components/responses/400'
500:
$ref: '#/components/responses/500'
"""
Expand Down

0 comments on commit a4756ba

Please sign in to comment.