From a1bfbd3fc788f3f068473d70fe4faf4f21a58451 Mon Sep 17 00:00:00 2001 From: JONEMI19 Date: Sat, 8 Jul 2023 09:57:15 +0000 Subject: [PATCH] add new routes to api schema --- tests/test_application.py | 1026 +++++++++++++++++++------------------ 1 file changed, 539 insertions(+), 487 deletions(-) diff --git a/tests/test_application.py b/tests/test_application.py index 8fa84b074..ba2942196 100644 --- a/tests/test_application.py +++ b/tests/test_application.py @@ -1,4 +1,6 @@ import pytest +from deepdiff import DeepDiff +from dirty_equals import IsDict from fastapi.testclient import TestClient from .main import app @@ -60,52 +62,72 @@ def test_openapi_schema(): "paths": { "/api_route": { "get": { - "summary": "Non Operation", - "operationId": "non_operation_api_route_get", "responses": { "200": { "description": "Successful Response", "content": {"application/json": {"schema": {}}}, } }, + "summary": "Non Operation", + "operationId": "non_operation_api_route_get", } }, "/non_decorated_route": { "get": { - "summary": "Non Decorated Route", - "operationId": "non_decorated_route_non_decorated_route_get", "responses": { "200": { "description": "Successful Response", "content": {"application/json": {"schema": {}}}, } }, + "summary": "Non Decorated Route", + "operationId": "non_decorated_route_non_decorated_route_get", } }, "/text": { "get": { - "summary": "Get Text", - "operationId": "get_text_text_get", "responses": { "200": { "description": "Successful Response", "content": {"application/json": {"schema": {}}}, } }, + "summary": "Get Text", + "operationId": "get_text_text_get", } }, "/path/{item_id}": { "get": { + "responses": { + "200": { + "description": "Successful Response", + "content": {"application/json": {"schema": {}}}, + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + }, + }, + }, "summary": "Get Id", "operationId": "get_id_path__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": {"title": "Item Id"}, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/str/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -122,20 +144,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/str/{item_id}": { - "get": { "summary": "Get Str Id", "operationId": "get_str_id_path_str__item_id__get", "parameters": [ { + "required": True, + "schema": {"title": "Item Id", "type": "string"}, "name": "item_id", "in": "path", - "required": True, - "schema": {"type": "string", "title": "Item Id"}, } ], + } + }, + "/path/int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -152,20 +174,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/int/{item_id}": { - "get": { "summary": "Get Int Id", "operationId": "get_int_id_path_int__item_id__get", "parameters": [ { + "required": True, + "schema": {"title": "Item Id", "type": "integer"}, "name": "item_id", "in": "path", - "required": True, - "schema": {"type": "integer", "title": "Item Id"}, } ], + } + }, + "/path/float/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -182,20 +204,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/float/{item_id}": { - "get": { "summary": "Get Float Id", "operationId": "get_float_id_path_float__item_id__get", "parameters": [ { + "required": True, + "schema": {"title": "Item Id", "type": "number"}, "name": "item_id", "in": "path", - "required": True, - "schema": {"type": "number", "title": "Item Id"}, } ], + } + }, + "/path/bool/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -212,20 +234,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/bool/{item_id}": { - "get": { "summary": "Get Bool Id", "operationId": "get_bool_id_path_bool__item_id__get", "parameters": [ { + "required": True, + "schema": {"title": "Item Id", "type": "boolean"}, "name": "item_id", "in": "path", - "required": True, - "schema": {"type": "boolean", "title": "Item Id"}, } ], + } + }, + "/path/param/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -242,10 +264,6 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param/{item_id}": { - "get": { "summary": "Get Path Param Id", "operationId": "get_path_param_id_path_param__item_id__get", "parameters": [ @@ -253,12 +271,20 @@ def test_openapi_schema(): "name": "item_id", "in": "path", "required": True, - "schema": { - "anyOf": [{"type": "string"}, {"type": "null"}], - "title": "Item Id", - }, + "schema": IsDict( + { + "anyOf": [{"type": "string"}, {"type": "null"}], + "title": "Item Id", + } + ) + # TODO: remove when deprecating Pydantic v1 + | IsDict({"title": "Item Id", "type": "string"}), } ], + } + }, + "/path/param-minlength/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -275,24 +301,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-minlength/{item_id}": { - "get": { "summary": "Get Path Param Min Length", "operationId": "get_path_param_min_length_path_param_minlength__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "string", - "minLength": 3, "title": "Item Id", + "minLength": 3, + "type": "string", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-maxlength/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -309,24 +335,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-maxlength/{item_id}": { - "get": { "summary": "Get Path Param Max Length", "operationId": "get_path_param_max_length_path_param_maxlength__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "string", - "maxLength": 3, "title": "Item Id", + "maxLength": 3, + "type": "string", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-min_maxlength/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -343,25 +369,25 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-min_maxlength/{item_id}": { - "get": { "summary": "Get Path Param Min Max Length", "operationId": "get_path_param_min_max_length_path_param_min_maxlength__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "string", - "minLength": 2, - "maxLength": 3, "title": "Item Id", + "maxLength": 3, + "minLength": 2, + "type": "string", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-gt/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -378,24 +404,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-gt/{item_id}": { - "get": { "summary": "Get Path Param Gt", "operationId": "get_path_param_gt_path_param_gt__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "exclusiveMinimum": 3, "title": "Item Id", + "exclusiveMinimum": 3.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-gt0/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -412,24 +438,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-gt0/{item_id}": { - "get": { "summary": "Get Path Param Gt0", "operationId": "get_path_param_gt0_path_param_gt0__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "exclusiveMinimum": 0, "title": "Item Id", + "exclusiveMinimum": 0.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-ge/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -446,24 +472,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-ge/{item_id}": { - "get": { "summary": "Get Path Param Ge", "operationId": "get_path_param_ge_path_param_ge__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "minimum": 3, "title": "Item Id", + "minimum": 3.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-lt/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -480,24 +506,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-lt/{item_id}": { - "get": { "summary": "Get Path Param Lt", "operationId": "get_path_param_lt_path_param_lt__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "exclusiveMaximum": 3, "title": "Item Id", + "exclusiveMaximum": 3.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-lt0/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -514,24 +540,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-lt0/{item_id}": { - "get": { "summary": "Get Path Param Lt0", "operationId": "get_path_param_lt0_path_param_lt0__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "exclusiveMaximum": 0, "title": "Item Id", + "exclusiveMaximum": 0.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-le/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -548,24 +574,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-le/{item_id}": { - "get": { "summary": "Get Path Param Le", "operationId": "get_path_param_le_path_param_le__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "maximum": 3, "title": "Item Id", + "maximum": 3.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-lt-gt/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -582,25 +608,25 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-lt-gt/{item_id}": { - "get": { "summary": "Get Path Param Lt Gt", "operationId": "get_path_param_lt_gt_path_param_lt_gt__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "exclusiveMaximum": 3, - "exclusiveMinimum": 1, "title": "Item Id", + "exclusiveMaximum": 3.0, + "exclusiveMinimum": 1.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-le-ge/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -617,25 +643,25 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-le-ge/{item_id}": { - "get": { "summary": "Get Path Param Le Ge", "operationId": "get_path_param_le_ge_path_param_le_ge__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "number", - "maximum": 3, - "minimum": 1, "title": "Item Id", + "maximum": 3.0, + "minimum": 1.0, + "type": "number", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-lt-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -652,24 +678,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-lt-int/{item_id}": { - "get": { "summary": "Get Path Param Lt Int", "operationId": "get_path_param_lt_int_path_param_lt_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "exclusiveMaximum": 3, "title": "Item Id", + "exclusiveMaximum": 3.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-gt-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -686,24 +712,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-gt-int/{item_id}": { - "get": { "summary": "Get Path Param Gt Int", "operationId": "get_path_param_gt_int_path_param_gt_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "exclusiveMinimum": 3, "title": "Item Id", + "exclusiveMinimum": 3.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-le-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -720,24 +746,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-le-int/{item_id}": { - "get": { "summary": "Get Path Param Le Int", "operationId": "get_path_param_le_int_path_param_le_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "maximum": 3, "title": "Item Id", + "maximum": 3.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-ge-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -754,24 +780,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-ge-int/{item_id}": { - "get": { "summary": "Get Path Param Ge Int", "operationId": "get_path_param_ge_int_path_param_ge_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "minimum": 3, "title": "Item Id", + "minimum": 3.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-lt-gt-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -788,25 +814,25 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-lt-gt-int/{item_id}": { - "get": { "summary": "Get Path Param Lt Gt Int", "operationId": "get_path_param_lt_gt_int_path_param_lt_gt_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "exclusiveMaximum": 3, - "exclusiveMinimum": 1, "title": "Item Id", + "exclusiveMaximum": 3.0, + "exclusiveMinimum": 1.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/path/param-le-ge-int/{item_id}": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -823,25 +849,25 @@ def test_openapi_schema(): }, }, }, - } - }, - "/path/param-le-ge-int/{item_id}": { - "get": { "summary": "Get Path Param Le Ge Int", "operationId": "get_path_param_le_ge_int_path_param_le_ge_int__item_id__get", "parameters": [ { - "name": "item_id", - "in": "path", "required": True, "schema": { - "type": "integer", - "maximum": 3, - "minimum": 1, "title": "Item Id", + "maximum": 3.0, + "minimum": 1.0, + "type": "integer", }, + "name": "item_id", + "in": "path", } ], + } + }, + "/query": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -858,20 +884,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query": { - "get": { "summary": "Get Query", "operationId": "get_query_query_get", "parameters": [ { - "name": "query", - "in": "query", "required": True, "schema": {"title": "Query"}, + "name": "query", + "in": "query", } ], + } + }, + "/query/optional": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -888,20 +914,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/optional": { - "get": { "summary": "Get Query Optional", "operationId": "get_query_optional_query_optional_get", "parameters": [ { - "name": "query", - "in": "query", "required": False, "schema": {"title": "Query"}, + "name": "query", + "in": "query", } ], + } + }, + "/query/int": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -918,20 +944,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/int": { - "get": { "summary": "Get Query Type", "operationId": "get_query_type_query_int_get", "parameters": [ { + "required": True, + "schema": {"title": "Query", "type": "integer"}, "name": "query", "in": "query", - "required": True, - "schema": {"type": "integer", "title": "Query"}, } ], + } + }, + "/query/int/optional": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -948,10 +974,6 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/int/optional": { - "get": { "summary": "Get Query Type Optional", "operationId": "get_query_type_optional_query_int_optional_get", "parameters": [ @@ -959,12 +981,20 @@ def test_openapi_schema(): "name": "query", "in": "query", "required": False, - "schema": { - "anyOf": [{"type": "integer"}, {"type": "null"}], - "title": "Query", - }, + "schema": IsDict( + { + "anyOf": [{"type": "integer"}, {"type": "null"}], + "title": "Query", + } + ) + # TODO: remove when deprecating Pydantic v1 + | IsDict({"title": "Query", "type": "integer"}), } ], + } + }, + "/query/int/default": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -981,24 +1011,24 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/int/default": { - "get": { "summary": "Get Query Type Int Default", "operationId": "get_query_type_int_default_query_int_default_get", "parameters": [ { - "name": "query", - "in": "query", "required": False, "schema": { + "title": "Query", "type": "integer", "default": 10, - "title": "Query", }, + "name": "query", + "in": "query", } ], + } + }, + "/query/param": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -1015,20 +1045,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/param": { - "get": { "summary": "Get Query Param", "operationId": "get_query_param_query_param_get", "parameters": [ { - "name": "query", - "in": "query", "required": False, "schema": {"title": "Query"}, + "name": "query", + "in": "query", } ], + } + }, + "/query/param-required": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -1045,20 +1075,20 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/param-required": { - "get": { "summary": "Get Query Param Required", "operationId": "get_query_param_required_query_param_required_get", "parameters": [ { - "name": "query", - "in": "query", "required": True, "schema": {"title": "Query"}, + "name": "query", + "in": "query", } ], + } + }, + "/query/param-required/int": { + "get": { "responses": { "200": { "description": "Successful Response", @@ -1075,56 +1105,45 @@ def test_openapi_schema(): }, }, }, - } - }, - "/query/param-required/int": { - "get": { "summary": "Get Query Param Required Type", "operationId": "get_query_param_required_type_query_param_required_int_get", "parameters": [ { + "required": True, + "schema": {"title": "Query", "type": "integer"}, "name": "query", "in": "query", - "required": True, - "schema": {"type": "integer", "title": "Query"}, } ], + } + }, + "/enum-status-code": { + "get": { "responses": { - "200": { + "201": { "description": "Successful Response", "content": {"application/json": {"schema": {}}}, }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } - }, - }, }, + "summary": "Get Enum Status Code", + "operationId": "get_enum_status_code_enum_status_code_get", } }, - "/query/sequence-params": { + "/query/frozenset": { "get": { - "summary": "Get Sequence Query Params", - "operationId": "get_sequence_query_params_query_sequence_params_get", + "summary": "Get Query Type Frozenset", + "operationId": "get_query_type_frozenset_query_frozenset_get", "parameters": [ { - "name": "query", - "in": "query", - "required": False, + "required": True, "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": {"type": "integer"}, - }, - "default": {}, "title": "Query", + "uniqueItems": True, + "type": "array", + "items": {"type": "integer"}, }, + "name": "query", + "in": "query", } ], "responses": { @@ -1145,275 +1164,308 @@ def test_openapi_schema(): }, } }, - "/query/mapping-params": { - "get": { - "summary": "Get Mapping Query Params", - "operationId": "get_mapping_query_params_query_mapping_params_get", - "parameters": [ - { - "name": "queries", - "in": "query", - "required": False, - "schema": { - "type": "object", - "additionalProperties": {"type": "string"}, - "default": {}, - "title": "Queries", - }, - } - ], - "responses": { - "200": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } + "/query/sequence-params": { + "get": { + "summary": "Get Sequence Query Params", + "operationId": "get_sequence_query_params_query_sequence_params_get", + "parameters": [ + { + "required": False, + "schema": { + "additionalProperties": { + "items": { + "type": "integer" }, + "type": "array" }, + "type": "object", + "title": "Query", + "default": {} }, + "name": "query", + "in": "query" } - }, - "/query/mapping-sequence-params": { - "get": { - "summary": "Get Sequence Mapping Query Params", - "operationId": "get_sequence_mapping_query_params_query_mapping_sequence_params_get", - "parameters": [ - { - "name": "queries", - "in": "query", - "required": False, + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": {} + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": {"type": "integer"}, - }, - "default": {}, - "title": "Queries", - }, + "$ref": "#/components/schemas/HTTPValidationError" + } } - ], - "responses": { - "200": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } - }, - }, + } + } + } + } + }, + "/query/mapping-params": { + "get": { + "summary": "Get Mapping Query Params", + "operationId": "get_mapping_query_params_query_mapping_params_get", + "parameters": [ + { + "required": False, + "schema": { + "additionalProperties": { + "type": "string" + }, + "type": "object", + "title": "Queries", + "default": {} }, + "name": "queries", + "in": "query" } - }, - "/query/mixed-params": { - "get": { - "summary": "Get Mixed Mapping Query Params", - "operationId": "get_mixed_mapping_query_params_query_mixed_params_get", - "parameters": [ - { - "name": "sequence_mapping_queries", - "in": "query", - "required": False, - "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": {"type": "string"}, - }, - "default": {}, - "title": "Sequence Mapping Queries", - }, - }, - { - "name": "mapping_query", - "in": "query", - "required": True, + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": {} + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { "schema": { - "type": "object", - "additionalProperties": {"type": "string"}, - "title": "Mapping Query", - }, - }, - { - "name": "query", - "in": "query", - "required": True, - "schema": {"type": "string", "title": "Query"}, - }, - ], - "responses": { - "200": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + } + }, + "/query/mapping-sequence-params": { + "get": { + "summary": "Get Sequence Mapping Query Params", + "operationId": "get_sequence_mapping_query_params_query_mapping_sequence_params_get", + "parameters": [ + { + "required": False, + "schema": { + "additionalProperties": { + "items": { + "type": "integer" }, + "type": "array" }, + "type": "object", + "title": "Queries", + "default": {} }, + "name": "queries", + "in": "query" } - }, - "/query/mixed-type-params": { - "get": { - "summary": "Get Mixed Mapping Mixed Type Query Params", - "operationId": "get_mixed_mapping_mixed_type_query_params_query_mixed_type_params_get", - "parameters": [ - { - "name": "sequence_mapping_queries", - "in": "query", - "required": False, - "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": {"type": "integer"}, - }, - "default": {}, - "title": "Sequence Mapping Queries", - }, - }, - { - "name": "mapping_query_str", - "in": "query", - "required": False, - "schema": { - "type": "object", - "additionalProperties": {"type": "string"}, - "default": {}, - "title": "Mapping Query Str", - }, - }, - { - "name": "mapping_query_int", - "in": "query", - "required": False, + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": {} + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { "schema": { - "type": "object", - "additionalProperties": {"type": "integer"}, - "default": {}, - "title": "Mapping Query Int", - }, - }, - { - "name": "query", - "in": "query", - "required": True, - "schema": {"type": "integer", "title": "Query"}, - }, - ], - "responses": { - "200": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + } + }, + "/query/mixed-params": { + "get": { + "summary": "Get Mixed Mapping Query Params", + "operationId": "get_mixed_mapping_query_params_query_mixed_params_get", + "parameters": [ + { + "required": False, + "schema": { + "additionalProperties": { + "items": { + "type": "string" }, + "type": "array" }, + "type": "object", + "title": "Sequence Mapping Queries", + "default": {} }, - } - }, - "/enum-status-code": { - "get": { - "summary": "Get Enum Status Code", - "operationId": "get_enum_status_code_enum_status_code_get", - "responses": { - "201": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - } + "name": "sequence_mapping_queries", + "in": "query" + }, + { + "required": True, + "schema": { + "additionalProperties": { + "type": "string" + }, + "type": "object", + "title": "Mapping Query" }, + "name": "mapping_query", + "in": "query" + }, + { + "required": True, + "schema": { + "type": "string", + "title": "Query" + }, + "name": "query", + "in": "query" } - }, - "/query/frozenset": { - "get": { - "summary": "Get Query Type Frozenset", - "operationId": "get_query_type_frozenset_query_frozenset_get", - "parameters": [ - { - "name": "query", - "in": "query", - "required": True, + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": {} + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { "schema": { - "type": "array", - "uniqueItems": True, - "items": {"type": "integer"}, - "title": "Query", - }, + "$ref": "#/components/schemas/HTTPValidationError" + } } - ], - "responses": { - "200": { - "description": "Successful Response", - "content": {"application/json": {"schema": {}}}, - }, - "422": { - "description": "Validation Error", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/HTTPValidationError" - } - } + } + } + } + } + }, + "/query/mixed-type-params": { + "get": { + "summary": "Get Mixed Mapping Mixed Type Query Params", + "operationId": "get_mixed_mapping_mixed_type_query_params_query_mixed_type_params_get", + "parameters": [ + { + "required": False, + "schema": { + "additionalProperties": { + "items": { + "type": "integer" }, + "type": "array" }, + "type": "object", + "title": "Sequence Mapping Queries", + "default": {} + }, + "name": "sequence_mapping_queries", + "in": "query" + }, + { + "required": False, + "schema": { + "additionalProperties": { + "type": "string" + }, + "type": "object", + "title": "Mapping Query Str", + "default": {} }, + "name": "mapping_query_str", + "in": "query" + }, + { + "required": False, + "schema": { + "additionalProperties": { + "type": "integer" + }, + "type": "object", + "title": "Mapping Query Int", + "default": {} + }, + "name": "mapping_query_int", + "in": "query" + }, + { + "required": True, + "schema": { + "type": "integer", + "title": "Query" + }, + "name": "query", + "in": "query" } - }, + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": {} + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + } + } }, "components": { "schemas": { - "HTTPValidationError": { - "properties": { - "detail": { - "items": {"$ref": "#/components/schemas/ValidationError"}, - "type": "array", - "title": "Detail", - } - }, - "type": "object", - "title": "HTTPValidationError", - }, "ValidationError": { + "title": "ValidationError", + "required": ["loc", "msg", "type"], + "type": "object", "properties": { "loc": { + "title": "Location", + "type": "array", "items": { "anyOf": [{"type": "string"}, {"type": "integer"}] }, - "type": "array", - "title": "Location", }, - "msg": {"type": "string", "title": "Message"}, - "type": {"type": "string", "title": "Error Type"}, + "msg": {"title": "Message", "type": "string"}, + "type": {"title": "Error Type", "type": "string"}, }, + }, + "HTTPValidationError": { + "title": "HTTPValidationError", "type": "object", - "required": ["loc", "msg", "type"], - "title": "ValidationError", + "properties": { + "detail": { + "title": "Detail", + "type": "array", + "items": {"$ref": "#/components/schemas/ValidationError"}, + } + }, }, } },