-- Dict
-- List
- UUID
- bool
- bytes
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java
index 710f7838d72f..79a482b9d573 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java
@@ -1771,7 +1771,8 @@ public DefaultCodegen() {
.build();
defaultIncludes = new HashSet<>(
- Arrays.asList("double",
+ Arrays.asList(
+ "double",
"int",
"long",
"short",
@@ -1784,7 +1785,19 @@ public DefaultCodegen() {
"Void",
"Integer",
"Long",
- "Float")
+ "Float",
+ // OpenAPI primitive/container keywords (these are schema-level concepts, not language types)
+ // and should never produce language import statements.
+ "string",
+ "number",
+ "integer",
+ "boolean",
+ "null",
+ "object",
+ "array",
+ "map",
+ "set"
+ )
);
typeMapping = new HashMap<>();
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java
index 4e246c7adadb..5e6bc51621cd 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java
@@ -51,6 +51,24 @@ public abstract class AbstractPythonCodegen extends DefaultCodegen implements Co
public static final String MAP_NUMBER_TO = "mapNumberTo";
+ /**
+ * Names which should never be treated as model imports for Python.
+ *
+ * These can leak into {@code CodegenModel.imports} from generic container/import collection logic
+ * (e.g. schema keywords like {@code array} or typing/builtin names), and then later get
+ * incorrectly converted into model import statements.
+ */
+ private static final Set PYTHON_NON_MODEL_IMPORTS = Collections.unmodifiableSet(new HashSet<>(
+ Arrays.asList(
+ // OpenAPI schema keywords (should never be imported)
+ "array", "map", "set", "object",
+ // Python builtins
+ "list", "dict", "tuple", "set", "type",
+ // typing names (capitalized)
+ "List", "Dict", "Tuple", "Set", "Type"
+ )
+ ));
+
protected String packageName = "openapi_client";
@Setter protected String packageVersion = "1.0.0";
@Setter protected String projectName; // for setup.py, e.g. petstore-api
@@ -101,8 +119,6 @@ public AbstractPythonCodegen() {
languageSpecificPrimitives.add("float");
languageSpecificPrimitives.add("list");
languageSpecificPrimitives.add("dict");
- languageSpecificPrimitives.add("List");
- languageSpecificPrimitives.add("Dict");
languageSpecificPrimitives.add("bool");
languageSpecificPrimitives.add("str");
languageSpecificPrimitives.add("datetime");
@@ -146,6 +162,21 @@ public AbstractPythonCodegen() {
regexModifiers.put('x', "VERBOSE");
}
+ @Override
+ protected boolean shouldAddImport(String type) {
+ if (type == null) {
+ return false;
+ }
+ // Reject type expressions (e.g. list[str], dict[str, Foo]) and other non-symbol entries early.
+ if (type.indexOf('[') >= 0 || type.indexOf(']') >= 0 || type.indexOf('<') >= 0 || type.indexOf('>') >= 0) {
+ return false;
+ }
+ if (PYTHON_NON_MODEL_IMPORTS.contains(type)) {
+ return false;
+ }
+ return super.shouldAddImport(type);
+ }
+
@Override
public void processOpts() {
super.processOpts();
@@ -896,7 +927,6 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) {
if (!model.oneOf.isEmpty()) { // oneOfValidationError
codegenProperties = model.getComposedSchemas().getOneOf();
moduleImports.add("typing", "Any");
- moduleImports.add("typing", "List");
moduleImports.add("pydantic", "Field");
moduleImports.add("pydantic", "StrictStr");
moduleImports.add("pydantic", "ValidationError");
@@ -932,11 +962,7 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) {
// if model_generic.mustache is used
if (model.oneOf.isEmpty() && model.anyOf.isEmpty() && !model.isEnum) {
moduleImports.add("typing", "ClassVar");
- moduleImports.add("typing", "Dict");
moduleImports.add("typing", "Any");
- if (this.disallowAdditionalPropertiesIfNotPresent || model.isAdditionalPropertiesTrue) {
- moduleImports.add("typing", "List");
- }
}
// if pydantic model
@@ -1571,7 +1597,7 @@ public PythonType addTypeParam(PythonType typeParam) {
* The Python / Pydantic type can be as expressive as needed:
*
* - it could simply be `str`
- * - or something more complex like `Optional[List[Dict[str, List[int]]]]`.
+ * - or something more complex like `Optional[list[dict[str, list[int]]]]`.
*
* Note that the default value (if available) and/or the metadata about
* the field / variable being defined are *not* part of the
@@ -1773,13 +1799,9 @@ private PythonType arrayType(IJsonSchemaValidationProperties cp) {
// Also, having a set instead of list creates complications:
// random JSON serialization order, unable to easily serialize
// to JSON, etc.
- //pt.setType("Set");
- //moduleImports.add("typing", "Set");
- pt.setType("List");
- moduleImports.add("typing", "List");
+ pt.setType("list");
} else {
- pt.setType("List");
- moduleImports.add("typing", "List");
+ pt.setType("list");
}
pt.addTypeParam(collectionItemType(cp.getItems()));
return pt;
@@ -1828,8 +1850,7 @@ private PythonType stringType(IJsonSchemaValidationProperties cp) {
}
private PythonType mapType(IJsonSchemaValidationProperties cp) {
- moduleImports.add("typing", "Dict");
- PythonType pt = new PythonType("Dict");
+ PythonType pt = new PythonType("dict");
pt.addTypeParam(new PythonType("str"));
pt.addTypeParam(collectionItemType(cp.getItems()));
return pt;
@@ -1954,9 +1975,7 @@ private PythonType binaryType(IJsonSchemaValidationProperties cp) {
pt.addTypeParam(strt);
if (cp.getIsBinary()) {
- moduleImports.add("typing", "Tuple");
-
- PythonType tt = new PythonType("Tuple");
+ PythonType tt = new PythonType("tuple");
// this string is a filename, not a validated value
tt.addTypeParam(new PythonType("str"));
tt.addTypeParam(bytest);
@@ -1976,9 +1995,7 @@ private PythonType binaryType(IJsonSchemaValidationProperties cp) {
pt.addTypeParam(new PythonType("StrictStr"));
if (cp.getIsBinary()) {
- moduleImports.add("typing", "Tuple");
-
- PythonType tt = new PythonType("Tuple");
+ PythonType tt = new PythonType("tuple");
tt.addTypeParam(new PythonType("StrictStr"));
tt.addTypeParam(new PythonType("StrictBytes"));
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonConnexionServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonConnexionServerCodegen.java
index a8eec2f60d0a..2b61b40b1d84 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonConnexionServerCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonConnexionServerCodegen.java
@@ -99,12 +99,6 @@ public AbstractPythonConnexionServerCodegen(String templateDirectory, boolean fi
simpleModule.addSerializer(Boolean.class, new PythonBooleanSerializer());
MAPPER.registerModule(simpleModule);
- // TODO may remove these later to default to the setting in abstract python base class instead
- languageSpecificPrimitives.add("List");
- languageSpecificPrimitives.add("Dict");
- typeMapping.put("array", "List");
- typeMapping.put("map", "Dict");
-
// set the output folder here
outputFolder = "generated-code" + File.separatorChar + "connexion";
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java
index 4d6c2e9713ea..922233b1b379 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java
@@ -48,6 +48,24 @@ public abstract class AbstractPythonPydanticV1Codegen extends DefaultCodegen imp
public static final String MAP_NUMBER_TO = "mapNumberTo";
+ /**
+ * Names which should never be treated as model imports for Python.
+ *
+ * These can leak into {@code CodegenModel.imports} from generic container/import collection logic
+ * (e.g. schema keywords like {@code array} or typing/builtin names), and then later get
+ * incorrectly converted into model import statements.
+ */
+ private static final Set PYTHON_NON_MODEL_IMPORTS = Collections.unmodifiableSet(new HashSet<>(
+ Arrays.asList(
+ // OpenAPI schema keywords (should never be imported)
+ "array", "map", "set", "object",
+ // Python builtins
+ "list", "dict", "tuple", "set", "type",
+ // typing names (capitalized)
+ "List", "Dict", "Tuple", "Set", "Type"
+ )
+ ));
+
protected String packageName = "openapi_client";
@Setter protected String packageVersion = "1.0.0";
@Setter protected String projectName; // for setup.py, e.g. petstore-api
@@ -91,8 +109,6 @@ public AbstractPythonPydanticV1Codegen() {
languageSpecificPrimitives.add("float");
languageSpecificPrimitives.add("list");
languageSpecificPrimitives.add("dict");
- languageSpecificPrimitives.add("List");
- languageSpecificPrimitives.add("Dict");
languageSpecificPrimitives.add("bool");
languageSpecificPrimitives.add("str");
languageSpecificPrimitives.add("datetime");
@@ -136,6 +152,21 @@ public AbstractPythonPydanticV1Codegen() {
regexModifiers.put('x', "VERBOSE");
}
+ @Override
+ protected boolean shouldAddImport(String type) {
+ if (type == null) {
+ return false;
+ }
+ // Reject type expressions (e.g. list[str], dict[str, Foo]) and other non-symbol entries early.
+ if (type.indexOf('[') >= 0 || type.indexOf(']') >= 0 || type.indexOf('<') >= 0 || type.indexOf('>') >= 0) {
+ return false;
+ }
+ if (PYTHON_NON_MODEL_IMPORTS.contains(type)) {
+ return false;
+ }
+ return super.shouldAddImport(type);
+ }
+
@Override
public void processOpts() {
super.processOpts();
@@ -843,7 +874,6 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) {
if (!model.oneOf.isEmpty()) { // oneOfValidationError
codegenProperties = model.getComposedSchemas().getOneOf();
typingImports.add("Any");
- typingImports.add("List");
pydanticImports.add("Field");
pydanticImports.add("StrictStr");
pydanticImports.add("ValidationError");
@@ -879,7 +909,6 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) {
if (model.oneOf.isEmpty() && model.anyOf.isEmpty()
&& !model.isEnum
&& !this.disallowAdditionalPropertiesIfNotPresent) {
- typingImports.add("Dict");
typingImports.add("Any");
}
@@ -1070,8 +1099,7 @@ private String getPydanticType(CodegenParameter cp,
getPydanticType(cp.items, typingImports, pydanticImports, datetimeImports, modelImports, exampleImports, postponedModelImports, postponedExampleImports, classname),
constraints);
} else if (cp.isMap) {
- typingImports.add("Dict");
- return String.format(Locale.ROOT, "Dict[str, %s]",
+ return String.format(Locale.ROOT, "dict[str, %s]",
getPydanticType(cp.items, typingImports, pydanticImports, datetimeImports, modelImports, exampleImports, postponedModelImports, postponedExampleImports, classname));
} else if (cp.isString) {
if (cp.hasValidation) {
@@ -1266,9 +1294,8 @@ private String getPydanticType(CodegenParameter cp,
} else if (cp.isUuid) {
return cp.dataType;
} else if (cp.isFreeFormObject) { // type: object
- typingImports.add("Dict");
typingImports.add("Any");
- return "Dict[str, Any]";
+ return "dict[str, Any]";
} else if (!cp.isPrimitiveType) {
// add model prefix
hasModelsToImport = true;
@@ -1351,13 +1378,11 @@ private String getPydanticType(CodegenProperty cp,
constraints += ", unique_items=True";
}
pydanticImports.add("conlist");
- typingImports.add("List"); // for return type
return String.format(Locale.ROOT, "conlist(%s%s)",
getPydanticType(cp.items, typingImports, pydanticImports, datetimeImports, modelImports, exampleImports, postponedModelImports, postponedExampleImports, classname),
constraints);
} else if (cp.isMap) {
- typingImports.add("Dict");
- return String.format(Locale.ROOT, "Dict[str, %s]", getPydanticType(cp.items, typingImports, pydanticImports, datetimeImports, modelImports, exampleImports, postponedModelImports, postponedExampleImports, classname));
+ return String.format(Locale.ROOT, "dict[str, %s]", getPydanticType(cp.items, typingImports, pydanticImports, datetimeImports, modelImports, exampleImports, postponedModelImports, postponedExampleImports, classname));
} else if (cp.isString) {
if (cp.hasValidation) {
List fieldCustomization = new ArrayList<>();
@@ -1550,9 +1575,8 @@ private String getPydanticType(CodegenProperty cp,
} else if (cp.isUuid) {
return cp.dataType;
} else if (cp.isFreeFormObject) { // type: object
- typingImports.add("Dict");
typingImports.add("Any");
- return "Dict[str, Any]";
+ return "dict[str, Any]";
} else if (!cp.isPrimitiveType || cp.isModel) { // model
// skip import if it's a circular reference
if (classname == null) {
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java
index fdf19feff107..b6cde077341d 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java
@@ -99,10 +99,7 @@ public PythonClientCodegen() {
// at the moment
importMapping.clear();
- // override type mapping in abstract python codegen
- typeMapping.put("array", "List");
- typeMapping.put("set", "List");
- typeMapping.put("map", "Dict");
+ // extend type mapping in abstract python codegen
typeMapping.put("decimal", "decimal.Decimal");
typeMapping.put("file", "bytes");
typeMapping.put("binary", "bytes");
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonFastAPIServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonFastAPIServerCodegen.java
index 2c61ad4e5a34..3701213a1069 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonFastAPIServerCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonFastAPIServerCodegen.java
@@ -118,11 +118,6 @@ public PythonFastAPIServerCodegen() {
additionalProperties.put(CodegenConstants.PACKAGE_NAME, DEFAULT_PACKAGE_NAME);
additionalProperties.put(CodegenConstants.FASTAPI_IMPLEMENTATION_PACKAGE, DEFAULT_IMPL_FOLDER);
- languageSpecificPrimitives.add("List");
- languageSpecificPrimitives.add("Dict");
- typeMapping.put("array", "List");
- typeMapping.put("map", "Dict");
-
outputFolder = "generated-code" + File.separator + NAME;
modelTemplateFiles.put("model.mustache", ".py");
apiTemplateFiles.put("api.mustache", ".py");
diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java
index ab529149d90e..e2a5392b5bcc 100644
--- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java
+++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java
@@ -93,10 +93,7 @@ public PythonPydanticV1ClientCodegen() {
// at the moment
importMapping.clear();
- // override type mapping in abstract python codegen
- typeMapping.put("array", "List");
- typeMapping.put("set", "List");
- typeMapping.put("map", "Dict");
+ // extend type mapping in abstract python codegen
typeMapping.put("decimal", "decimal.Decimal");
typeMapping.put("file", "bytearray");
typeMapping.put("binary", "bytearray");
diff --git a/modules/openapi-generator/src/main/resources/python-aiohttp/controller.mustache b/modules/openapi-generator/src/main/resources/python-aiohttp/controller.mustache
index 170f65ed4b19..0d7e2bd39e5a 100644
--- a/modules/openapi-generator/src/main/resources/python-aiohttp/controller.mustache
+++ b/modules/openapi-generator/src/main/resources/python-aiohttp/controller.mustache
@@ -1,4 +1,3 @@
-from typing import List, Dict
from aiohttp import web
{{#imports}}{{import}}
@@ -36,7 +35,7 @@ async def {{operationId}}(request: web.Request, {{#allParams}}{{paramName}}{{^re
{{#isArray}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: List[{{>param_type}}]
+ :type {{paramName}}: list[{{>param_type}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: list | bytes
@@ -46,7 +45,7 @@ async def {{operationId}}(request: web.Request, {{#allParams}}{{paramName}}{{^re
{{#isMap}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: Dict[str, {{>param_type}}]
+ :type {{paramName}}: dict[str, {{>param_type}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: dict | bytes
diff --git a/modules/openapi-generator/src/main/resources/python-aiohttp/model.mustache b/modules/openapi-generator/src/main/resources/python-aiohttp/model.mustache
index 227baea3fdf4..dfbc45285507 100644
--- a/modules/openapi-generator/src/main/resources/python-aiohttp/model.mustache
+++ b/modules/openapi-generator/src/main/resources/python-aiohttp/model.mustache
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from {{modelPackage}}.base_model import Model
{{#models}}
{{#model}}
diff --git a/modules/openapi-generator/src/main/resources/python-aiohttp/security_controller.mustache b/modules/openapi-generator/src/main/resources/python-aiohttp/security_controller.mustache
index df74618a9ffc..f801742f22ad 100644
--- a/modules/openapi-generator/src/main/resources/python-aiohttp/security_controller.mustache
+++ b/modules/openapi-generator/src/main/resources/python-aiohttp/security_controller.mustache
@@ -1,5 +1,3 @@
-from typing import List
-
{{#authMethods}}
{{#isOAuth}}
@@ -14,7 +12,7 @@ def info_from_{{name}}(token: str) -> dict:
return {'scopes': ['read:pets', 'write:pets'], 'uid': 'user_id'}
-def validate_scope_{{name}}(required_scopes: List[str], token_scopes: List[str]) -> bool:
+def validate_scope_{{name}}(required_scopes: list[str], token_scopes: list[str]) -> bool:
""" Validate required scopes are included in token scope """
return set(required_scopes).issubset(set(token_scopes))
diff --git a/modules/openapi-generator/src/main/resources/python-aiohttp/typing_utils.mustache b/modules/openapi-generator/src/main/resources/python-aiohttp/typing_utils.mustache
index 0563f81fd534..9b3eabf41907 100644
--- a/modules/openapi-generator/src/main/resources/python-aiohttp/typing_utils.mustache
+++ b/modules/openapi-generator/src/main/resources/python-aiohttp/typing_utils.mustache
@@ -10,11 +10,11 @@ if sys.version_info < (3, 7):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -24,9 +24,9 @@ else:
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list
diff --git a/modules/openapi-generator/src/main/resources/python-aiohttp/util.mustache b/modules/openapi-generator/src/main/resources/python-aiohttp/util.mustache
index 1b1eadc7ee2a..0948bca35810 100644
--- a/modules/openapi-generator/src/main/resources/python-aiohttp/util.mustache
+++ b/modules/openapi-generator/src/main/resources/python-aiohttp/util.mustache
@@ -5,7 +5,7 @@ from typing import Union
from {{packageName}} import typing_utils
T = typing.TypeVar('T')
-Class = typing.Type[T]
+Class = type[T]
def _deserialize(data: Union[dict, list, str], klass: Union[Class, str]) -> Union[dict, list, Class, int, float, str, bool, datetime.date, datetime.datetime]:
diff --git a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/controllers/controller.mustache b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/controllers/controller.mustache
index afba1f7cfefb..3095b7c054d0 100644
--- a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/controllers/controller.mustache
+++ b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/controllers/controller.mustache
@@ -35,7 +35,7 @@ def {{operationId}}({{#allParams}}{{paramName}}{{^required}}=None{{/required}}{{
{{#isArray}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: List[{{#isString}}str{{/isString}}{{#isInteger}}int{{/isInteger}}{{#isLong}}int{{/isLong}}{{#isFloat}}float{{/isFloat}}{{#isDouble}}float{{/isDouble}}{{#isByteArray}}str{{/isByteArray}}{{#isBinary}}str{{/isBinary}}{{#isBoolean}}bool{{/isBoolean}}{{#isDate}}str{{/isDate}}{{#isDateTime}}str{{/isDateTime}}]
+ :type {{paramName}}: list[{{#isString}}str{{/isString}}{{#isInteger}}int{{/isInteger}}{{#isLong}}int{{/isLong}}{{#isFloat}}float{{/isFloat}}{{#isDouble}}float{{/isDouble}}{{#isByteArray}}str{{/isByteArray}}{{#isBinary}}str{{/isBinary}}{{#isBoolean}}bool{{/isBoolean}}{{#isDate}}str{{/isDate}}{{#isDateTime}}str{{/isDateTime}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: list | bytes
@@ -45,7 +45,7 @@ def {{operationId}}({{#allParams}}{{paramName}}{{^required}}=None{{/required}}{{
{{#isMap}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: Dict[str, {{#isString}}str{{/isString}}{{#isInteger}}int{{/isInteger}}{{#isLong}}int{{/isLong}}{{#isFloat}}float{{/isFloat}}{{#isDouble}}float{{/isDouble}}{{#isByteArray}}str{{/isByteArray}}{{#isBinary}}str{{/isBinary}}{{#isBoolean}}bool{{/isBoolean}}{{#isDate}}str{{/isDate}}{{#isDateTime}}str{{/isDateTime}}]
+ :type {{paramName}}: dict[str, {{#isString}}str{{/isString}}{{#isInteger}}int{{/isInteger}}{{#isLong}}int{{/isLong}}{{#isFloat}}float{{/isFloat}}{{#isDouble}}float{{/isDouble}}{{#isByteArray}}str{{/isByteArray}}{{#isBinary}}str{{/isBinary}}{{#isBoolean}}bool{{/isBoolean}}{{#isDate}}str{{/isDate}}{{#isDateTime}}str{{/isDateTime}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: dict | bytes
diff --git a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/base_model.mustache b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/base_model.mustache
index 07a5e26b5b09..125300867e74 100644
--- a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/base_model.mustache
+++ b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/base_model.mustache
@@ -17,7 +17,7 @@ class Model(object):
attribute_map = {}
@classmethod
- def from_dict(cls: typing.Type[T], dikt) -> T:
+ def from_dict(cls: type[T], dikt) -> T:
"""Returns the dict as a model"""
return util.deserialize_model(dikt, cls)
diff --git a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/model.mustache b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/model.mustache
index 999c1d879a61..b05f0c1ebae5 100644
--- a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/model.mustache
+++ b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/models/model.mustache
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from {{modelPackage}}.base_model import Model
{{#imports}}{{import}} # noqa: F401,E501
{{/imports}}
diff --git a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/typing_utils.mustache b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/typing_utils.mustache
index 0563f81fd534..9b3eabf41907 100644
--- a/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/typing_utils.mustache
+++ b/modules/openapi-generator/src/main/resources/python-blueplanet/app/{{packageName}}/typing_utils.mustache
@@ -10,11 +10,11 @@ if sys.version_info < (3, 7):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -24,9 +24,9 @@ else:
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/api.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/api.mustache
index 0680d357cda6..3f112afd5e19 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/api.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/api.mustache
@@ -1,6 +1,5 @@
# coding: utf-8
-from typing import Dict, List # noqa: F401
import importlib
import pkgutil
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/base_api.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/base_api.mustache
index d1d95c12eff8..4142856feb93 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/base_api.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/base_api.mustache
@@ -1,6 +1,6 @@
# coding: utf-8
-from typing import ClassVar, Dict, List, Tuple # noqa: F401
+from typing import ClassVar
{{#imports}}
{{import}}
@@ -8,7 +8,7 @@ from typing import ClassVar, Dict, List, Tuple # noqa: F401
{{#securityImports.0}}from {{packageName}}.security_api import {{#securityImports}}get_token_{{.}}{{^-last}}, {{/-last}}{{/securityImports}}{{/securityImports.0}}
class Base{{classname}}:
- subclasses: ClassVar[Tuple] = ()
+ subclasses: ClassVar[tuple] = ()
def __init_subclass__(cls, **kwargs):
super().__init_subclass__(**kwargs)
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/model_anyof.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/model_anyof.mustache
index b145f73ad13b..435a5fbae1a3 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/model_anyof.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/model_anyof.mustache
@@ -12,7 +12,7 @@ import re # noqa: F401
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Union, Any, List, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal
from pydantic import StrictStr, Field
try:
@@ -35,7 +35,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
actual_instance: Optional[Union[{{#anyOf}}{{{.}}}{{^-last}}, {{/-last}}{{/anyOf}}]] = None
else:
actual_instance: Any = None
- any_of_schemas: List[str] = Literal[{{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ANY_OF_SCHEMAS]
+ any_of_schemas: list[str] = Literal[{{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ANY_OF_SCHEMAS]
model_config = {
"validate_assignment": True,
@@ -43,7 +43,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
}
{{#discriminator}}
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
{{#children}}
'{{^vendorExtensions.x-discriminator-value}}{{name}}{{/vendorExtensions.x-discriminator-value}}{{#vendorExtensions.x-discriminator-value}}{{{vendorExtensions.x-discriminator-value}}}{{/vendorExtensions.x-discriminator-value}}': '{{{classname}}}'{{^-last}},{{/-last}}
{{/children}}
@@ -167,7 +167,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Dict:
+ def to_dict(self) -> dict:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return "null"
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache
index e5e64a08ebeb..fd293b35c7db 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache
@@ -25,9 +25,9 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{name}}: {{{vendorExtensions.x-py-typing}}}
{{/vars}}
{{#isAdditionalPropertiesTrue}}
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
{{/isAdditionalPropertiesTrue}}
- __properties: ClassVar[List[str]] = [{{#allVars}}"{{baseName}}"{{^-last}}, {{/-last}}{{/allVars}}]
+ __properties: ClassVar[list[str]] = [{{#allVars}}"{{baseName}}"{{^-last}}, {{/-last}}{{/allVars}}]
{{#vars}}
{{#vendorExtensions.x-regex}}
@@ -90,15 +90,15 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{#hasChildren}}
{{#discriminator}}
# JSON field name that stores the object type
- __discriminator_property_name: ClassVar[List[str]] = '{{discriminator.propertyBaseName}}'
+ __discriminator_property_name: ClassVar[list[str]] = '{{discriminator.propertyBaseName}}'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
{{#mappedModels}}'{{{mappingName}}}': '{{{modelName}}}'{{^-last}},{{/-last}}{{/mappedModels}}
}
@classmethod
- def get_discriminator_value(cls, obj: Dict) -> str:
+ def get_discriminator_value(cls, obj: dict) -> str:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -122,7 +122,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
"""Create an instance of {{{classname}}} from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -238,7 +238,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> {{^hasChildren}}Self{{/hasChildren}}{{#hasChildren}}{{#discriminator}}Union[{{#children}}Self{{^-last}}, {{/-last}}{{/children}}]{{/discriminator}}{{^discriminator}}Self{{/discriminator}}{{/hasChildren}}:
+ def from_dict(cls, obj: dict) -> {{^hasChildren}}Self{{/hasChildren}}{{#hasChildren}}{{#discriminator}}Union[{{#children}}Self{{^-last}}, {{/-last}}{{/children}}]{{/discriminator}}{{^discriminator}}Self{{/discriminator}}{{/hasChildren}}:
"""Create an instance of {{{classname}}} from a dict"""
{{#hasChildren}}
{{#discriminator}}
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/model_oneof.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/model_oneof.mustache
index b87c42cf2b9b..b746caf02c33 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/model_oneof.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/model_oneof.mustache
@@ -12,7 +12,7 @@ import re # noqa: F401
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Union, Any, List, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal
from pydantic import StrictStr, Field
try:
@@ -31,7 +31,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{vendorExtensions.x-py-name}}: {{{vendorExtensions.x-py-typing}}}
{{/composedSchemas.oneOf}}
actual_instance: Optional[Union[{{#oneOf}}{{{.}}}{{^-last}}, {{/-last}}{{/oneOf}}]] = None
- one_of_schemas: List[str] = Literal[{{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}}]
+ one_of_schemas: list[str] = Literal[{{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}}]
model_config = {
"validate_assignment": True,
@@ -40,7 +40,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{#discriminator}}
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
{{#children}}
'{{^vendorExtensions.x-discriminator-value}}{{name}}{{/vendorExtensions.x-discriminator-value}}{{#vendorExtensions.x-discriminator-value}}{{{vendorExtensions.x-discriminator-value}}}{{/vendorExtensions.x-discriminator-value}}': '{{{classname}}}'{{^-last}},{{/-last}}
{{/children}}
@@ -190,7 +190,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Dict:
+ def to_dict(self) -> dict:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/security_api.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/security_api.mustache
index 4fda1a8f91db..d8b55cbfe084 100644
--- a/modules/openapi-generator/src/main/resources/python-fastapi/security_api.mustache
+++ b/modules/openapi-generator/src/main/resources/python-fastapi/security_api.mustache
@@ -1,7 +1,5 @@
# coding: utf-8
-from typing import List
-
from fastapi import Depends, Security # noqa: F401
from fastapi.openapi.models import OAuthFlowImplicit, OAuthFlows # noqa: F401
from fastapi.security import ( # noqa: F401
@@ -74,15 +72,15 @@ def get_token_{{name}}(
def validate_scope_{{name}}(
- required_scopes: SecurityScopes, token_scopes: List[str]
+ required_scopes: SecurityScopes, token_scopes: list[str]
) -> bool:
"""
Validate required scopes are included in token scope
:param required_scopes Required scope to access called API
- :type required_scopes: List[str]
+ :type required_scopes: list[str]
:param token_scopes Scope present in token
- :type token_scopes: List[str]
+ :type token_scopes: list[str]
:return: True if access to called API is allowed
:rtype: bool
"""
diff --git a/modules/openapi-generator/src/main/resources/python-flask/base_model.mustache b/modules/openapi-generator/src/main/resources/python-flask/base_model.mustache
index 33b96e27b55b..36f630b7309b 100644
--- a/modules/openapi-generator/src/main/resources/python-flask/base_model.mustache
+++ b/modules/openapi-generator/src/main/resources/python-flask/base_model.mustache
@@ -10,14 +10,14 @@ T = typing.TypeVar('T')
class Model:
# openapiTypes: The key is attribute name and the
# value is attribute type.
- openapi_types: typing.Dict[str, type] = {}
+ openapi_types: dict[str, type] = {}
# attributeMap: The key is attribute name and the
# value is json key in definition.
- attribute_map: typing.Dict[str, str] = {}
+ attribute_map: dict[str, str] = {}
@classmethod
- def from_dict(cls: typing.Type[T], dikt) -> T:
+ def from_dict(cls: type[T], dikt) -> T:
"""Returns the dict as a model"""
return util.deserialize_model(dikt, cls)
diff --git a/modules/openapi-generator/src/main/resources/python-flask/controller.mustache b/modules/openapi-generator/src/main/resources/python-flask/controller.mustache
index 74034f5e8695..1646b73f0207 100644
--- a/modules/openapi-generator/src/main/resources/python-flask/controller.mustache
+++ b/modules/openapi-generator/src/main/resources/python-flask/controller.mustache
@@ -1,6 +1,4 @@
import connexion
-from typing import Dict
-from typing import Tuple
from typing import Union
{{#imports}}{{import}} # noqa: E501
@@ -38,7 +36,7 @@ def {{operationId}}({{#allParams}}{{^isBodyParam}}{{paramName}}{{/isBodyParam}}{
{{#isArray}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: List[{{>param_type}}]
+ :type {{paramName}}: list[{{>param_type}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: list | bytes
@@ -48,7 +46,7 @@ def {{operationId}}({{#allParams}}{{^isBodyParam}}{{paramName}}{{/isBodyParam}}{
{{#isMap}}
{{#items}}
{{#isPrimitiveType}}
- :type {{paramName}}: Dict[str, {{>param_type}}]
+ :type {{paramName}}: dict[str, {{>param_type}}]
{{/isPrimitiveType}}
{{^isPrimitiveType}}
:type {{paramName}}: dict | bytes
@@ -57,7 +55,7 @@ def {{operationId}}({{#allParams}}{{^isBodyParam}}{{paramName}}{{/isBodyParam}}{
{{/isMap}}
{{/allParams}}
- :rtype: Union[{{returnType}}{{^returnType}}None{{/returnType}}, Tuple[{{returnType}}{{^returnType}}None{{/returnType}}, int], Tuple[{{returnType}}{{^returnType}}None{{/returnType}}, int, Dict[str, str]]
+ :rtype: Union[{{returnType}}{{^returnType}}None{{/returnType}}, tuple[{{returnType}}{{^returnType}}None{{/returnType}}, int], tuple[{{returnType}}{{^returnType}}None{{/returnType}}, int, dict[str, str]]
"""
{{#allParams}}
{{#isBodyParam}}
diff --git a/modules/openapi-generator/src/main/resources/python-flask/model.mustache b/modules/openapi-generator/src/main/resources/python-flask/model.mustache
index bf1818f6c104..9cbf6f65ace3 100644
--- a/modules/openapi-generator/src/main/resources/python-flask/model.mustache
+++ b/modules/openapi-generator/src/main/resources/python-flask/model.mustache
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from {{modelPackage}}.base_model import Model
{{#models}}
{{#model}}
diff --git a/modules/openapi-generator/src/main/resources/python-flask/security_controller.mustache b/modules/openapi-generator/src/main/resources/python-flask/security_controller.mustache
index a5f3d6d5312e..521134e9d479 100644
--- a/modules/openapi-generator/src/main/resources/python-flask/security_controller.mustache
+++ b/modules/openapi-generator/src/main/resources/python-flask/security_controller.mustache
@@ -1,5 +1,3 @@
-from typing import List
-
{{#authMethods}}
{{#isOAuth}}
@@ -23,9 +21,9 @@ def validate_scope_{{name}}(required_scopes, token_scopes):
Validate required scopes are included in token scope
:param required_scopes Required scope to access called API
- :type required_scopes: List[str]
+ :type required_scopes: list[str]
:param token_scopes Scope present in token
- :type token_scopes: List[str]
+ :type token_scopes: list[str]
:return: True if access to called API is allowed
:rtype: bool
"""
diff --git a/modules/openapi-generator/src/main/resources/python-flask/typing_utils.mustache b/modules/openapi-generator/src/main/resources/python-flask/typing_utils.mustache
index 74e3c913a7db..154d655510ba 100644
--- a/modules/openapi-generator/src/main/resources/python-flask/typing_utils.mustache
+++ b/modules/openapi-generator/src/main/resources/python-flask/typing_utils.mustache
@@ -8,11 +8,11 @@ if sys.version_info < (3, 7):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -22,9 +22,9 @@ else:
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list
diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_client.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_client.mustache
index de8406407329..0d3b99199777 100644
--- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_client.mustache
+++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_client.mustache
@@ -363,13 +363,13 @@ class ApiClient:
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- sub_kls = re.match(r'List\[(.*)]', klass).group(1)
+ if klass.startswith('list['):
+ sub_kls = re.match(r'list\[(.*)]', klass).group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- sub_kls = re.match(r'Dict\[([^,]*), (.*)]', klass).group(2)
+ if klass.startswith('dict['):
+ sub_kls = re.match(r'dict\[([^,]*), (.*)]', klass).group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_response.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_response.mustache
index a0b62b95246c..0ce9c905789f 100644
--- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_response.mustache
+++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/api_response.mustache
@@ -1,7 +1,7 @@
"""API response object."""
from __future__ import annotations
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictInt, StrictStr
class ApiResponse:
@@ -10,7 +10,7 @@ class ApiResponse:
"""
status_code: Optional[StrictInt] = Field(None, description="HTTP status code")
- headers: Optional[Dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
+ headers: Optional[dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
data: Optional[Any] = Field(None, description="Deserialized data given the data type")
raw_data: Optional[Any] = Field(None, description="Raw data (HTTP response body)")
diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_anyof.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_anyof.mustache
index e76bd81c46d1..98ffcbca5d17 100644
--- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_anyof.mustache
+++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_anyof.mustache
@@ -9,7 +9,7 @@ import re # noqa: F401
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
{{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ANY_OF_SCHEMAS = [{{#anyOf}}"{{.}}"{{^-last}}, {{/-last}}{{/anyOf}}]
@@ -27,7 +27,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
actual_instance: Union[{{#anyOf}}{{{.}}}{{^-last}}, {{/-last}}{{/anyOf}}]
else:
actual_instance: Any
- any_of_schemas: List[str] = Field({{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ANY_OF_SCHEMAS, const=True)
+ any_of_schemas: list[str] = Field({{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ANY_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache
index 6ac505ab55ec..498fcb6c7a20 100644
--- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache
+++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache
@@ -30,7 +30,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{name}}: {{{vendorExtensions.x-py-typing}}}
{{/vars}}
{{#isAdditionalPropertiesTrue}}
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
{{/isAdditionalPropertiesTrue}}
__properties = [{{#allVars}}"{{baseName}}"{{^-last}}, {{/-last}}{{/allVars}}]
{{#vars}}
diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_oneof.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_oneof.mustache
index 2f23bade3418..40f8f5f6250e 100644
--- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_oneof.mustache
+++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_oneof.mustache
@@ -9,7 +9,7 @@ import re # noqa: F401
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
{{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ONE_OF_SCHEMAS = [{{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}}]
@@ -26,7 +26,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
actual_instance: Union[{{#oneOf}}{{{.}}}{{^-last}}, {{/-last}}{{/oneOf}}]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field({{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field({{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/modules/openapi-generator/src/main/resources/python/api.mustache b/modules/openapi-generator/src/main/resources/python/api.mustache
index 241398eb598b..26fbaa260d02 100644
--- a/modules/openapi-generator/src/main/resources/python/api.mustache
+++ b/modules/openapi-generator/src/main/resources/python/api.mustache
@@ -2,7 +2,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
{{#imports}}
@@ -91,7 +91,7 @@ class {{classname}}:
_host = None
{{/servers.0}}
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
{{#allParams}}
{{#isArray}}
'{{baseName}}': '{{collectionFormat}}',
@@ -99,12 +99,12 @@ class {{classname}}:
{{/allParams}}
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -218,7 +218,7 @@ class {{classname}}:
{{/hasConsumes}}
# authentication setting
- _auth_settings: List[str] = [{{#authMethods}}
+ _auth_settings: list[str] = [{{#authMethods}}
'{{name}}'{{^-last}}, {{/-last}}{{/authMethods}}
]
diff --git a/modules/openapi-generator/src/main/resources/python/api_client.mustache b/modules/openapi-generator/src/main/resources/python/api_client.mustache
index e414300cd095..b18632bee98a 100644
--- a/modules/openapi-generator/src/main/resources/python/api_client.mustache
+++ b/modules/openapi-generator/src/main/resources/python/api_client.mustache
@@ -13,7 +13,7 @@ import tempfile
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
{{#tornado}}
import tornado.gen
@@ -33,7 +33,7 @@ from {{packageName}}.exceptions import (
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -294,7 +294,7 @@ class ApiClient:
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -442,16 +442,16 @@ class ApiClient:
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -486,7 +486,7 @@ class ApiClient:
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -516,7 +516,7 @@ class ApiClient:
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -550,7 +550,7 @@ class ApiClient:
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -583,7 +583,7 @@ class ApiClient:
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/modules/openapi-generator/src/main/resources/python/configuration.mustache b/modules/openapi-generator/src/main/resources/python/configuration.mustache
index 4027fe59b15c..60c820110f21 100644
--- a/modules/openapi-generator/src/main/resources/python/configuration.mustache
+++ b/modules/openapi-generator/src/main/resources/python/configuration.mustache
@@ -14,7 +14,7 @@ from logging import FileHandler
import multiprocessing
{{/async}}
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
{{^async}}
@@ -31,7 +31,7 @@ JSON_SCHEMA_VALIDATION_KEYWORDS = {
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -146,13 +146,13 @@ AuthSettings = TypedDict(
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -304,8 +304,8 @@ conf = {{{packageName}}}.Configuration(
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
@@ -314,8 +314,8 @@ conf = {{{packageName}}}.Configuration(
{{/hasHttpSignatureMethods}}
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
{{#asyncio}}
@@ -485,7 +485,7 @@ conf = {{{packageName}}}.Configuration(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -745,7 +745,7 @@ conf = {{{packageName}}}.Configuration(
"SDK Package Version: {{packageVersion}}".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -789,7 +789,7 @@ conf = {{{packageName}}}.Configuration(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/modules/openapi-generator/src/main/resources/python/model_anyof.mustache b/modules/openapi-generator/src/main/resources/python/model_anyof.mustache
index e035e4829b6f..7960797e33fb 100644
--- a/modules/openapi-generator/src/main/resources/python/model_anyof.mustache
+++ b/modules/openapi-generator/src/main/resources/python/model_anyof.mustache
@@ -9,7 +9,7 @@ import re # noqa: F401
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
@@ -28,7 +28,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
actual_instance: Optional[Union[{{#anyOf}}{{{.}}}{{^-last}}, {{/-last}}{{/anyOf}}]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { {{#anyOf}}"{{.}}"{{^-last}}, {{/-last}}{{/anyOf}} }
+ any_of_schemas: set[str] = { {{#anyOf}}"{{.}}"{{^-last}}, {{/-last}}{{/anyOf}} }
model_config = {
"validate_assignment": True,
@@ -36,7 +36,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
}
{{#discriminator}}
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
{{#children}}
'{{^vendorExtensions.x-discriminator-value}}{{name}}{{/vendorExtensions.x-discriminator-value}}{{#vendorExtensions.x-discriminator-value}}{{{vendorExtensions.x-discriminator-value}}}{{/vendorExtensions.x-discriminator-value}}': '{{{classname}}}'{{^-last}},{{/-last}}
{{/children}}
@@ -95,7 +95,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -159,7 +159,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], {{#anyOf}}{{.}}{{^-last}}, {{/-last}}{{/anyOf}}]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], {{#anyOf}}{{.}}{{^-last}}, {{/-last}}{{/anyOf}}]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/modules/openapi-generator/src/main/resources/python/model_generic.mustache b/modules/openapi-generator/src/main/resources/python/model_generic.mustache
index 1b9d0f7d3fd8..fb9ac20efa97 100644
--- a/modules/openapi-generator/src/main/resources/python/model_generic.mustache
+++ b/modules/openapi-generator/src/main/resources/python/model_generic.mustache
@@ -9,7 +9,7 @@ import json
{{#vendorExtensions.x-py-model-imports}}
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,9 +32,9 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{name}}: {{{vendorExtensions.x-py-typing}}}
{{/vars}}
{{#isAdditionalPropertiesTrue}}
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
{{/isAdditionalPropertiesTrue}}
- __properties: ClassVar[List[str]] = [{{#allVars}}"{{baseName}}"{{^-last}}, {{/-last}}{{/allVars}}]
+ __properties: ClassVar[list[str]] = [{{#allVars}}"{{baseName}}"{{^-last}}, {{/-last}}{{/allVars}}]
{{#vars}}
{{#vendorExtensions.x-regex}}
@@ -111,12 +111,12 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
__discriminator_property_name: ClassVar[str] = '{{discriminator.propertyBaseName}}'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
{{#mappedModels}}'{{{mappingName}}}': '{{{modelName}}}'{{^-last}},{{/-last}}{{/mappedModels}}
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -139,7 +139,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
"""Create an instance of {{{classname}}} from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -155,7 +155,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
* Fields in `self.additional_properties` are added to the output dict.
{{/isAdditionalPropertiesTrue}}
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
{{#vendorExtensions.x-py-readonly}}
"{{{.}}}",
{{/vendorExtensions.x-py-readonly}}
@@ -288,7 +288,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{#hasChildren}}
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[{{#discriminator}}Union[{{#mappedModels}}{{{modelName}}}{{^-last}}, {{/-last}}{{/mappedModels}}]{{/discriminator}}{{^discriminator}}Self{{/discriminator}}]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[{{#discriminator}}Union[{{#mappedModels}}{{{modelName}}}{{^-last}}, {{/-last}}{{/mappedModels}}]{{/discriminator}}{{^discriminator}}Self{{/discriminator}}]:
"""Create an instance of {{{classname}}} from a dict"""
{{#discriminator}}
# look up the object type based on discriminator mapping
@@ -305,7 +305,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{/hasChildren}}
{{^hasChildren}}
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of {{{classname}}} from a dict"""
if obj is None:
return None
diff --git a/modules/openapi-generator/src/main/resources/python/model_oneof.mustache b/modules/openapi-generator/src/main/resources/python/model_oneof.mustache
index 07a4d93f9ddf..5cb4158486c4 100644
--- a/modules/openapi-generator/src/main/resources/python/model_oneof.mustache
+++ b/modules/openapi-generator/src/main/resources/python/model_oneof.mustache
@@ -8,7 +8,7 @@ import pprint
{{{.}}}
{{/vendorExtensions.x-py-model-imports}}
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
{{#lambda.uppercase}}{{{classname}}}{{/lambda.uppercase}}_ONE_OF_SCHEMAS = [{{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}}]
@@ -22,7 +22,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{vendorExtensions.x-py-name}}: {{{vendorExtensions.x-py-typing}}}
{{/composedSchemas.oneOf}}
actual_instance: Optional[Union[{{#oneOf}}{{{.}}}{{^-last}}, {{/-last}}{{/oneOf}}]] = None
- one_of_schemas: Set[str] = { {{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}} }
+ one_of_schemas: set[str] = { {{#oneOf}}"{{.}}"{{^-last}}, {{/-last}}{{/oneOf}} }
model_config = ConfigDict(
validate_assignment=True,
@@ -31,7 +31,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
{{#discriminator}}
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
{{#children}}
'{{^vendorExtensions.x-discriminator-value}}{{name}}{{/vendorExtensions.x-discriminator-value}}{{#vendorExtensions.x-discriminator-value}}{{{vendorExtensions.x-discriminator-value}}}{{/vendorExtensions.x-discriminator-value}}': '{{{classname}}}'{{^-last}},{{/-last}}
{{/children}}
@@ -93,7 +93,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -185,7 +185,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}}
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], {{#oneOf}}{{{.}}}{{^-last}}, {{/-last}}{{/oneOf}}]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], {{#oneOf}}{{{.}}}{{^-last}}, {{/-last}}{{/oneOf}}]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/modules/openapi-generator/src/main/resources/python/partial_api.mustache b/modules/openapi-generator/src/main/resources/python/partial_api.mustache
index dd3a9a1fa12b..0d2b9191f808 100644
--- a/modules/openapi-generator/src/main/resources/python/partial_api.mustache
+++ b/modules/openapi-generator/src/main/resources/python/partial_api.mustache
@@ -43,7 +43,7 @@
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
{{#responses}}
{{^isWildcard}}
'{{code}}': {{#dataType}}"{{.}}"{{/dataType}}{{^dataType}}None{{/dataType}},
diff --git a/modules/openapi-generator/src/main/resources/python/partial_api_args.mustache b/modules/openapi-generator/src/main/resources/python/partial_api_args.mustache
index 379b67de9875..01282e8feed0 100644
--- a/modules/openapi-generator/src/main/resources/python/partial_api_args.mustache
+++ b/modules/openapi-generator/src/main/resources/python/partial_api_args.mustache
@@ -6,13 +6,13 @@
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le={{#servers.size}}{{servers.size}}{{/servers.size}}{{^servers.size}}1{{/servers.size}})] = 0,
)
\ No newline at end of file
diff --git a/modules/openapi-generator/src/main/resources/python/signing.mustache b/modules/openapi-generator/src/main/resources/python/signing.mustache
index 4d00424ea48f..4b5119be9a97 100644
--- a/modules/openapi-generator/src/main/resources/python/signing.mustache
+++ b/modules/openapi-generator/src/main/resources/python/signing.mustache
@@ -12,7 +12,7 @@ from email.utils import formatdate
import os
import re
from time import time
-from typing import List, Optional, Union
+from typing import Optional, Union
from urllib.parse import urlencode, urlparse
# The constants below define a subset of HTTP headers that can be included in the
@@ -118,7 +118,7 @@ class HttpSigningConfiguration:
signing_scheme: str,
private_key_path: str,
private_key_passphrase: Union[None, str]=None,
- signed_headers: Optional[List[str]]=None,
+ signed_headers: Optional[list[str]]=None,
signing_algorithm: Optional[str]=None,
hash_algorithm: Optional[str]=None,
signature_max_validity: Optional[timedelta]=None,
diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonClientCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonClientCodegenTest.java
index f5bc24393993..bfad9f05718c 100644
--- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonClientCodegenTest.java
+++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonClientCodegenTest.java
@@ -240,6 +240,14 @@ public void listPropertyTest() {
Assert.assertEquals(cm.classname, "Sample");
Assert.assertEquals(cm.description, "a sample model");
Assert.assertEquals(cm.vars.size(), 2);
+ // Ensure schema/container keywords and Python container/typing names do not leak into model imports.
+ Assert.assertFalse(cm.imports.contains("array"));
+ Assert.assertFalse(cm.imports.contains("map"));
+ Assert.assertFalse(cm.imports.contains("set"));
+ Assert.assertFalse(cm.imports.contains("list"));
+ Assert.assertFalse(cm.imports.contains("dict"));
+ Assert.assertFalse(cm.imports.contains("List"));
+ Assert.assertFalse(cm.imports.contains("Dict"));
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "id");
@@ -252,10 +260,10 @@ public void listPropertyTest() {
final CodegenProperty property2 = cm.vars.get(1);
Assert.assertEquals(property2.baseName, "urls");
- Assert.assertEquals(property2.dataType, "List[str]");
+ Assert.assertEquals(property2.dataType, "list[str]");
Assert.assertEquals(property2.name, "urls");
Assert.assertNull(property2.defaultValue);
- Assert.assertEquals(property2.baseType, "List");
+ Assert.assertEquals(property2.baseType, "list");
Assert.assertEquals(property2.containerType, "array");
Assert.assertFalse(property2.required);
Assert.assertTrue(property2.isPrimitiveType);
@@ -278,12 +286,20 @@ public void mapPropertyTest() {
Assert.assertEquals(cm.classname, "Sample");
Assert.assertEquals(cm.description, "a sample model");
Assert.assertEquals(cm.vars.size(), 1);
+ // Ensure schema/container keywords and Python container/typing names do not leak into model imports.
+ Assert.assertFalse(cm.imports.contains("array"));
+ Assert.assertFalse(cm.imports.contains("map"));
+ Assert.assertFalse(cm.imports.contains("set"));
+ Assert.assertFalse(cm.imports.contains("list"));
+ Assert.assertFalse(cm.imports.contains("dict"));
+ Assert.assertFalse(cm.imports.contains("List"));
+ Assert.assertFalse(cm.imports.contains("Dict"));
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "translations");
- Assert.assertEquals(property1.dataType, "Dict[str, str]");
+ Assert.assertEquals(property1.dataType, "dict[str, str]");
Assert.assertEquals(property1.name, "translations");
- Assert.assertEquals(property1.baseType, "Dict");
+ Assert.assertEquals(property1.baseType, "dict");
Assert.assertEquals(property1.containerType, "map");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -333,9 +349,9 @@ public void complexListPropertyTest() {
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "children");
Assert.assertEquals(property1.complexType, "Children");
- Assert.assertEquals(property1.dataType, "List[Children]");
+ Assert.assertEquals(property1.dataType, "list[Children]");
Assert.assertEquals(property1.name, "children");
- Assert.assertEquals(property1.baseType, "List");
+ Assert.assertEquals(property1.baseType, "list");
Assert.assertEquals(property1.containerType, "array");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -361,9 +377,9 @@ public void complexMapPropertyTest() {
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "children");
Assert.assertEquals(property1.complexType, "Children");
- Assert.assertEquals(property1.dataType, "Dict[str, Children]");
+ Assert.assertEquals(property1.dataType, "dict[str, Children]");
Assert.assertEquals(property1.name, "children");
- Assert.assertEquals(property1.baseType, "Dict");
+ Assert.assertEquals(property1.baseType, "dict");
Assert.assertEquals(property1.containerType, "map");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -468,7 +484,7 @@ public void testContainerType() {
op = codegen.fromOperation(path, "post", p, null);
Assert.assertEquals(op.allParams.get(0).baseName, "User");
Assert.assertEquals(op.allParams.get(0).containerType, "array");
- Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "List");
+ Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "list");
path = "/pet";
p = openAPI.getPaths().get(path).getPost();
@@ -489,7 +505,7 @@ public void testContainerTypeForDict() {
Operation p = openAPI.getPaths().get(path).getGet();
CodegenOperation op = codegen.fromOperation(path, "get", p, null);
Assert.assertEquals(op.allParams.get(0).containerType, "map");
- Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "Dict");
+ Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "dict");
Assert.assertEquals(op.allParams.get(0).baseName, "dict_string_integer");
}
diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonFastAPIServerCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonFastAPIServerCodegenTest.java
index 5858e4fbd27f..1fd5b12511dd 100644
--- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonFastAPIServerCodegenTest.java
+++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonFastAPIServerCodegenTest.java
@@ -52,6 +52,6 @@ public void testContainerType() throws IOException {
final Path p = Paths.get(outputPath + "src/openapi_server/apis/default_api.py");
assertFileExists(p);
- assertFileContains(p, "body: Optional[Dict[str, Any]] = Body(None, description=\"\"),");
+ assertFileContains(p, "body: Optional[dict[str, Any]] = Body(None, description=\"\"),");
}
}
diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonPydanticV1ClientCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonPydanticV1ClientCodegenTest.java
index 1c2fd629ce3b..244d0334524e 100644
--- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonPydanticV1ClientCodegenTest.java
+++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/python/PythonPydanticV1ClientCodegenTest.java
@@ -234,6 +234,14 @@ public void listPropertyTest() {
Assert.assertEquals(cm.classname, "Sample");
Assert.assertEquals(cm.description, "a sample model");
Assert.assertEquals(cm.vars.size(), 2);
+ // Ensure schema/container keywords and Python container/typing names do not leak into model imports.
+ Assert.assertFalse(cm.imports.contains("array"));
+ Assert.assertFalse(cm.imports.contains("map"));
+ Assert.assertFalse(cm.imports.contains("set"));
+ Assert.assertFalse(cm.imports.contains("list"));
+ Assert.assertFalse(cm.imports.contains("dict"));
+ Assert.assertFalse(cm.imports.contains("List"));
+ Assert.assertFalse(cm.imports.contains("Dict"));
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "id");
@@ -246,10 +254,10 @@ public void listPropertyTest() {
final CodegenProperty property2 = cm.vars.get(1);
Assert.assertEquals(property2.baseName, "urls");
- Assert.assertEquals(property2.dataType, "List[str]");
+ Assert.assertEquals(property2.dataType, "list[str]");
Assert.assertEquals(property2.name, "urls");
Assert.assertNull(property2.defaultValue);
- Assert.assertEquals(property2.baseType, "List");
+ Assert.assertEquals(property2.baseType, "list");
Assert.assertEquals(property2.containerType, "array");
Assert.assertFalse(property2.required);
Assert.assertTrue(property2.isPrimitiveType);
@@ -272,12 +280,20 @@ public void mapPropertyTest() {
Assert.assertEquals(cm.classname, "Sample");
Assert.assertEquals(cm.description, "a sample model");
Assert.assertEquals(cm.vars.size(), 1);
+ // Ensure schema/container keywords and Python container/typing names do not leak into model imports.
+ Assert.assertFalse(cm.imports.contains("array"));
+ Assert.assertFalse(cm.imports.contains("map"));
+ Assert.assertFalse(cm.imports.contains("set"));
+ Assert.assertFalse(cm.imports.contains("list"));
+ Assert.assertFalse(cm.imports.contains("dict"));
+ Assert.assertFalse(cm.imports.contains("List"));
+ Assert.assertFalse(cm.imports.contains("Dict"));
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "translations");
- Assert.assertEquals(property1.dataType, "Dict[str, str]");
+ Assert.assertEquals(property1.dataType, "dict[str, str]");
Assert.assertEquals(property1.name, "translations");
- Assert.assertEquals(property1.baseType, "Dict");
+ Assert.assertEquals(property1.baseType, "dict");
Assert.assertEquals(property1.containerType, "map");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -327,9 +343,9 @@ public void complexListPropertyTest() {
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "children");
Assert.assertEquals(property1.complexType, "Children");
- Assert.assertEquals(property1.dataType, "List[Children]");
+ Assert.assertEquals(property1.dataType, "list[Children]");
Assert.assertEquals(property1.name, "children");
- Assert.assertEquals(property1.baseType, "List");
+ Assert.assertEquals(property1.baseType, "list");
Assert.assertEquals(property1.containerType, "array");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -355,9 +371,9 @@ public void complexMapPropertyTest() {
final CodegenProperty property1 = cm.vars.get(0);
Assert.assertEquals(property1.baseName, "children");
Assert.assertEquals(property1.complexType, "Children");
- Assert.assertEquals(property1.dataType, "Dict[str, Children]");
+ Assert.assertEquals(property1.dataType, "dict[str, Children]");
Assert.assertEquals(property1.name, "children");
- Assert.assertEquals(property1.baseType, "Dict");
+ Assert.assertEquals(property1.baseType, "dict");
Assert.assertEquals(property1.containerType, "map");
Assert.assertFalse(property1.required);
Assert.assertTrue(property1.isContainer);
@@ -462,7 +478,7 @@ public void testContainerType() {
op = codegen.fromOperation(path, "post", p, null);
Assert.assertEquals(op.allParams.get(0).baseName, "User");
Assert.assertEquals(op.allParams.get(0).containerType, "array");
- Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "List");
+ Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "list");
path = "/pet";
p = openAPI.getPaths().get(path).getPost();
@@ -483,7 +499,7 @@ public void testContainerTypeForDict() {
Operation p = openAPI.getPaths().get(path).getGet();
CodegenOperation op = codegen.fromOperation(path, "get", p, null);
Assert.assertEquals(op.allParams.get(0).containerType, "map");
- Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "Dict");
+ Assert.assertEquals(op.allParams.get(0).containerTypeMapped, "dict");
Assert.assertEquals(op.allParams.get(0).baseName, "dict_string_integer");
}
diff --git a/modules/openapi-generator/src/test/resources/3_0/unit_test_spec/spec_writer.py b/modules/openapi-generator/src/test/resources/3_0/unit_test_spec/spec_writer.py
index 51c4b0ee0e35..192521cb1a32 100644
--- a/modules/openapi-generator/src/test/resources/3_0/unit_test_spec/spec_writer.py
+++ b/modules/openapi-generator/src/test/resources/3_0/unit_test_spec/spec_writer.py
@@ -38,10 +38,10 @@ class JsonSchemaTestCase:
'JsonSchema',
{
'additionalProperties': 'JsonSchema',
- 'allOf': typing.List['JsonSchema'],
- 'anyOf': typing.List['JsonSchema'],
+ 'allOf': list['JsonSchema'],
+ 'anyOf': list['JsonSchema'],
'default': typing.Any,
- 'enum': typing.List[typing.Any],
+ 'enum': list[typing.Any],
'exclusiveMaximum': typing.Union[int, float],
'exclusiveMinimum': typing.Union[int, float],
'format': str,
@@ -56,11 +56,11 @@ class JsonSchemaTestCase:
'minProperties': int,
'multipleOf': typing.Union[int, float],
'not': 'JsonSchema',
- 'oneOf': typing.List['JsonSchema'],
+ 'oneOf': list['JsonSchema'],
'pattern': str,
- 'properties': typing.Dict[str, 'JsonSchema'],
+ 'properties': dict[str, 'JsonSchema'],
'$ref': str,
- 'required': typing.List[str],
+ 'required': list[str],
'type': str,
'uniqueItems': bool,
},
@@ -73,7 +73,7 @@ class JsonSchemaTestCase:
class JsonSchemaTestSchema:
description: str
schema: JsonSchema
- tests: typing.List[JsonSchemaTestCase]
+ tests: list[JsonSchemaTestCase]
comment: typing.Optional[str] = None
@@ -266,7 +266,7 @@ class ExclusionReason:
'unknownKeyword': None
}
-def get_json_schema_test_schemas(file_path: typing.Tuple[str]) -> typing.List[JsonSchemaTestSchema]:
+def get_json_schema_test_schemas(file_path: tuple[str]) -> list[JsonSchemaTestSchema]:
json_schema_test_schemas = []
filename = file_path[-1]
exclude_file_reason = FILEPATH_TO_EXCLUDE_REASON.get(file_path)
@@ -297,19 +297,19 @@ def get_json_schema_test_schemas(file_path: typing.Tuple[str]) -> typing.List[Js
{
'type': str,
'items': 'OpenApiSchema',
- 'properties': typing.Dict[str, 'OpenApiSchema'],
+ 'properties': dict[str, 'OpenApiSchema'],
'$ref': str
},
total=False
)
-JsonSchemaTestCases = typing.Dict[str, JsonSchemaTestCase]
+JsonSchemaTestCases = dict[str, JsonSchemaTestCase]
OpenApiComponents = typing.TypedDict(
'OpenApiComponents',
{
- 'schemas': typing.Dict[str, OpenApiSchema],
- 'x-schema-test-examples': typing.Dict[str, JsonSchemaTestCases]
+ 'schemas': dict[str, OpenApiSchema],
+ 'x-schema-test-examples': dict[str, JsonSchemaTestCases]
}
)
@@ -324,21 +324,21 @@ def get_json_schema_test_schemas(file_path: typing.Tuple[str]) -> typing.List[Js
class OpenApiRequestBody(typing.TypedDict, total=False):
description: str
- content: typing.Dict[str, OpenApiMediaType]
+ content: dict[str, OpenApiMediaType]
required: bool
class OpenApiResponseObject(typing.TypedDict):
description: str
- headers: typing.Optional[typing.Dict[str, typing.Any]] = None
- content: typing.Optional[typing.Dict[str, OpenApiMediaType]] = None
+ headers: typing.Optional[dict[str, typing.Any]] = None
+ content: typing.Optional[dict[str, OpenApiMediaType]] = None
class OpenApiOperation(typing.TypedDict, total=False):
- tags: typing.List[str]
+ tags: list[str]
summary: str
description: str
operationId: str
requestBody: OpenApiRequestBody
- responses: typing.Dict[str, OpenApiResponseObject]
+ responses: dict[str, OpenApiResponseObject]
class OpenApiPathItem(typing.TypedDict, total=False):
summary: str
@@ -352,7 +352,7 @@ class OpenApiPathItem(typing.TypedDict, total=False):
patch: OpenApiOperation
trace: OpenApiOperation
-OpenApiPaths = typing.Dict[str, OpenApiPathItem]
+OpenApiPaths = dict[str, OpenApiPathItem]
@dataclasses.dataclass
@@ -375,9 +375,9 @@ class OpenApiServer:
@dataclasses.dataclass
class OpenApiDocument:
openapi: str
- servers: typing.List[OpenApiServer]
+ servers: list[OpenApiServer]
info: OpenApiDocumentInfo
- tags: typing.List[OpenApiTag]
+ tags: list[OpenApiTag]
paths: OpenApiPaths
components: OpenApiComponents
@@ -409,8 +409,8 @@ def get_test_case_name(test: JsonSchemaTestSchema) -> str:
def get_component_schemas_and_test_examples(
json_schema_test_file: str,
- folders: typing.Tuple[str]
-) -> typing.Tuple[typing.Dict[str, OpenApiSchema], typing.Dict[str, typing.Dict[str, JsonSchemaTestSchema]]]:
+ folders: tuple[str]
+) -> tuple[dict[str, OpenApiSchema], dict[str, dict[str, JsonSchemaTestSchema]]]:
component_schemas = {}
component_name_to_test_examples = {}
for folder in folders:
@@ -433,7 +433,7 @@ def get_component_schemas_and_test_examples(
def generate_post_operation_with_request_body(
component_name: str,
- tags: typing.List[OpenApiTag]
+ tags: list[OpenApiTag]
) -> OpenApiOperation:
method = 'post'
ref_schema_path = f'#/components/schemas/{component_name}'
@@ -464,7 +464,7 @@ def generate_post_operation_with_request_body(
def generate_post_operation_with_response_content_schema(
component_name: str,
- tags: typing.List[OpenApiTag]
+ tags: list[OpenApiTag]
) -> OpenApiOperation:
method = 'post'
ref_schema_path = f'#/components/schemas/{component_name}'
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/BodyApi.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/BodyApi.md
index 86be9cc416c4..aab0c5e74db9 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/BodyApi.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/BodyApi.md
@@ -172,7 +172,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.BodyApi(api_client)
- files = None # List[bytes] |
+ files = None # list[bytes] |
try:
# Test array of binary in multipart mime
@@ -190,7 +190,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **files** | **List[bytes]**| |
+ **files** | **list[bytes]**| |
### Return type
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/DefaultValue.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/DefaultValue.md
index 7c1668c0d6c6..8459d262b344 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/DefaultValue.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/DefaultValue.md
@@ -6,13 +6,13 @@ to test the default value of properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_string_enum_ref_default** | [**List[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
-**array_string_enum_default** | **List[str]** | | [optional] [default to ["success","failure"]]
-**array_string_default** | **List[str]** | | [optional] [default to ["failure","skipped"]]
-**array_integer_default** | **List[int]** | | [optional] [default to [1,3]]
-**array_string** | **List[str]** | | [optional]
-**array_string_nullable** | **List[str]** | | [optional]
-**array_string_extension_nullable** | **List[str]** | | [optional]
+**array_string_enum_ref_default** | [**list[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
+**array_string_enum_default** | **list[str]** | | [optional] [default to ["success","failure"]]
+**array_string_default** | **list[str]** | | [optional] [default to ["failure","skipped"]]
+**array_integer_default** | **list[int]** | | [optional] [default to [1,3]]
+**array_string** | **list[str]** | | [optional]
+**array_string_nullable** | **list[str]** | | [optional]
+**array_string_extension_nullable** | **list[str]** | | [optional]
**string_nullable** | **str** | | [optional]
## Example
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Pet.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Pet.md
index 99b4bf3ab010..ee8124b0063d 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Pet.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**name** | **str** | |
**category** | [**Category**](Category.md) | | [optional]
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Query.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Query.md
index d39693eb5b93..cc247b24b821 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Query.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/Query.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **int** | Query | [optional]
-**outcomes** | **List[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
+**outcomes** | **list[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
## Example
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/QueryApi.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/QueryApi.md
index dc1a241c15c2..1b28ad01380e 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/QueryApi.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/QueryApi.md
@@ -390,7 +390,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = [56] # List[int] | (optional)
+ query_object = [56] # list[int] | (optional)
try:
# Test query parameter(s)
@@ -408,7 +408,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[int]**](int.md)| | [optional]
+ **query_object** | [**list[int]**](int.md)| | [optional]
### Return type
@@ -457,7 +457,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = ['query_object_example'] # List[str] | (optional)
+ query_object = ['query_object_example'] # list[str] | (optional)
try:
# Test query parameter(s)
@@ -475,7 +475,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[str]**](str.md)| | [optional]
+ **query_object** | [**list[str]**](str.md)| | [optional]
### Return type
@@ -729,7 +729,7 @@ with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
json_serialized_object_ref_string_query = openapi_client.Pet() # Pet | (optional)
- json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # List[Pet] | (optional)
+ json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # list[Pet] | (optional)
try:
# Test query parameter(s)
@@ -748,7 +748,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**json_serialized_object_ref_string_query** | [**Pet**](.md)| | [optional]
- **json_serialized_object_array_ref_string_query** | [**List[Pet]**](Pet.md)| | [optional]
+ **json_serialized_object_array_ref_string_query** | [**list[Pet]**](Pet.md)| | [optional]
### Return type
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
index 846a0941a09c..2c861924ec43 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**values** | **List[str]** | | [optional]
+**values** | **list[str]** | | [optional]
## Example
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/auth_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/auth_api.py
index 3ad40309ce6f..47ccb190b020 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/auth_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/auth_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictStr
@@ -42,14 +42,14 @@ def test_auth_http_basic(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""To test HTTP basic authentication
@@ -85,7 +85,7 @@ def test_auth_http_basic(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -105,14 +105,14 @@ def test_auth_http_basic_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""To test HTTP basic authentication
@@ -148,7 +148,7 @@ def test_auth_http_basic_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -168,14 +168,14 @@ def test_auth_http_basic_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test HTTP basic authentication
@@ -211,7 +211,7 @@ def test_auth_http_basic_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -231,15 +231,15 @@ def _test_auth_http_basic_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -260,7 +260,7 @@ def _test_auth_http_basic_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_auth'
]
@@ -288,14 +288,14 @@ def test_auth_http_bearer(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""To test HTTP bearer authentication
@@ -331,7 +331,7 @@ def test_auth_http_bearer(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -351,14 +351,14 @@ def test_auth_http_bearer_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""To test HTTP bearer authentication
@@ -394,7 +394,7 @@ def test_auth_http_bearer_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -414,14 +414,14 @@ def test_auth_http_bearer_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test HTTP bearer authentication
@@ -457,7 +457,7 @@ def test_auth_http_bearer_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -477,15 +477,15 @@ def _test_auth_http_bearer_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -506,7 +506,7 @@ def _test_auth_http_bearer_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_bearer_auth'
]
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/body_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/body_api.py
index c4b05d54f131..f5144333c166 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/body_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/body_api.py
@@ -13,11 +13,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictStr
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from openapi_client.models.pet import Pet
from openapi_client.models.string_enum_ref import StringEnumRef
@@ -47,14 +47,14 @@ def test_binary_gif(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""Test binary (gif) response body
@@ -90,7 +90,7 @@ def test_binary_gif(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -110,14 +110,14 @@ def test_binary_gif_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""Test binary (gif) response body
@@ -153,7 +153,7 @@ def test_binary_gif_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -173,14 +173,14 @@ def test_binary_gif_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test binary (gif) response body
@@ -216,7 +216,7 @@ def test_binary_gif_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -236,15 +236,15 @@ def _test_binary_gif_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -265,7 +265,7 @@ def _test_binary_gif_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -289,18 +289,18 @@ def _test_binary_gif_serialize(
@validate_call
def test_body_application_octetstream_binary(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test body parameter(s)
@@ -339,7 +339,7 @@ def test_body_application_octetstream_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -356,18 +356,18 @@ def test_body_application_octetstream_binary(
@validate_call
def test_body_application_octetstream_binary_with_http_info(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test body parameter(s)
@@ -406,7 +406,7 @@ def test_body_application_octetstream_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -423,18 +423,18 @@ def test_body_application_octetstream_binary_with_http_info(
@validate_call
def test_body_application_octetstream_binary_without_preload_content(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -473,7 +473,7 @@ def test_body_application_octetstream_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -494,15 +494,15 @@ def _test_body_application_octetstream_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -546,7 +546,7 @@ def _test_body_application_octetstream_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -570,18 +570,18 @@ def _test_body_application_octetstream_binary_serialize(
@validate_call
def test_body_multipart_formdata_array_of_binary(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test array of binary in multipart mime
@@ -589,7 +589,7 @@ def test_body_multipart_formdata_array_of_binary(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -620,7 +620,7 @@ def test_body_multipart_formdata_array_of_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -637,18 +637,18 @@ def test_body_multipart_formdata_array_of_binary(
@validate_call
def test_body_multipart_formdata_array_of_binary_with_http_info(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test array of binary in multipart mime
@@ -656,7 +656,7 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -687,7 +687,7 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -704,18 +704,18 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
@validate_call
def test_body_multipart_formdata_array_of_binary_without_preload_content(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test array of binary in multipart mime
@@ -723,7 +723,7 @@ def test_body_multipart_formdata_array_of_binary_without_preload_content(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -754,7 +754,7 @@ def test_body_multipart_formdata_array_of_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -775,16 +775,16 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'files': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -820,7 +820,7 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -844,18 +844,18 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
@validate_call
def test_body_multipart_formdata_single_binary(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test single binary in multipart mime
@@ -894,7 +894,7 @@ def test_body_multipart_formdata_single_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -911,18 +911,18 @@ def test_body_multipart_formdata_single_binary(
@validate_call
def test_body_multipart_formdata_single_binary_with_http_info(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test single binary in multipart mime
@@ -961,7 +961,7 @@ def test_body_multipart_formdata_single_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -978,18 +978,18 @@ def test_body_multipart_formdata_single_binary_with_http_info(
@validate_call
def test_body_multipart_formdata_single_binary_without_preload_content(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test single binary in multipart mime
@@ -1028,7 +1028,7 @@ def test_body_multipart_formdata_single_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1049,15 +1049,15 @@ def _test_body_multipart_formdata_single_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1093,7 +1093,7 @@ def _test_body_multipart_formdata_single_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1121,14 +1121,14 @@ def test_echo_body_all_of_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Test body parameter(s)
@@ -1167,7 +1167,7 @@ def test_echo_body_all_of_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1188,14 +1188,14 @@ def test_echo_body_all_of_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Test body parameter(s)
@@ -1234,7 +1234,7 @@ def test_echo_body_all_of_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1255,14 +1255,14 @@ def test_echo_body_all_of_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -1301,7 +1301,7 @@ def test_echo_body_all_of_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1322,15 +1322,15 @@ def _test_echo_body_all_of_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1366,7 +1366,7 @@ def _test_echo_body_all_of_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1390,18 +1390,18 @@ def _test_echo_body_all_of_pet_serialize(
@validate_call
def test_echo_body_free_form_object_response_string(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test free form object
@@ -1440,7 +1440,7 @@ def test_echo_body_free_form_object_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1457,18 +1457,18 @@ def test_echo_body_free_form_object_response_string(
@validate_call
def test_echo_body_free_form_object_response_string_with_http_info(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test free form object
@@ -1507,7 +1507,7 @@ def test_echo_body_free_form_object_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1524,18 +1524,18 @@ def test_echo_body_free_form_object_response_string_with_http_info(
@validate_call
def test_echo_body_free_form_object_response_string_without_preload_content(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test free form object
@@ -1574,7 +1574,7 @@ def test_echo_body_free_form_object_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1595,15 +1595,15 @@ def _test_echo_body_free_form_object_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1639,7 +1639,7 @@ def _test_echo_body_free_form_object_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1667,14 +1667,14 @@ def test_echo_body_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Test body parameter(s)
@@ -1713,7 +1713,7 @@ def test_echo_body_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1734,14 +1734,14 @@ def test_echo_body_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Test body parameter(s)
@@ -1780,7 +1780,7 @@ def test_echo_body_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1801,14 +1801,14 @@ def test_echo_body_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -1847,7 +1847,7 @@ def test_echo_body_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1868,15 +1868,15 @@ def _test_echo_body_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1912,7 +1912,7 @@ def _test_echo_body_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1940,14 +1940,14 @@ def test_echo_body_pet_response_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test empty response body
@@ -1986,7 +1986,7 @@ def test_echo_body_pet_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2007,14 +2007,14 @@ def test_echo_body_pet_response_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test empty response body
@@ -2053,7 +2053,7 @@ def test_echo_body_pet_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2074,14 +2074,14 @@ def test_echo_body_pet_response_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test empty response body
@@ -2120,7 +2120,7 @@ def test_echo_body_pet_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2141,15 +2141,15 @@ def _test_echo_body_pet_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2185,7 +2185,7 @@ def _test_echo_body_pet_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2213,14 +2213,14 @@ def test_echo_body_string_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> StringEnumRef:
"""Test string enum response body
@@ -2259,7 +2259,7 @@ def test_echo_body_string_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2280,14 +2280,14 @@ def test_echo_body_string_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[StringEnumRef]:
"""Test string enum response body
@@ -2326,7 +2326,7 @@ def test_echo_body_string_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2347,14 +2347,14 @@ def test_echo_body_string_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test string enum response body
@@ -2393,7 +2393,7 @@ def test_echo_body_string_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2414,15 +2414,15 @@ def _test_echo_body_string_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2458,7 +2458,7 @@ def _test_echo_body_string_enum_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2486,14 +2486,14 @@ def test_echo_body_tag_response_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test empty json (request body)
@@ -2532,7 +2532,7 @@ def test_echo_body_tag_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2553,14 +2553,14 @@ def test_echo_body_tag_response_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test empty json (request body)
@@ -2599,7 +2599,7 @@ def test_echo_body_tag_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2620,14 +2620,14 @@ def test_echo_body_tag_response_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test empty json (request body)
@@ -2666,7 +2666,7 @@ def test_echo_body_tag_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2687,15 +2687,15 @@ def _test_echo_body_tag_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2731,7 +2731,7 @@ def _test_echo_body_tag_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
index e4e3ddffa3ac..69d966602e86 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr
@@ -47,14 +47,14 @@ def test_form_integer_boolean_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s)
@@ -99,7 +99,7 @@ def test_form_integer_boolean_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -122,14 +122,14 @@ def test_form_integer_boolean_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s)
@@ -174,7 +174,7 @@ def test_form_integer_boolean_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -197,14 +197,14 @@ def test_form_integer_boolean_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s)
@@ -249,7 +249,7 @@ def test_form_integer_boolean_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -272,15 +272,15 @@ def _test_form_integer_boolean_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -320,7 +320,7 @@ def _test_form_integer_boolean_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -348,14 +348,14 @@ def test_form_object_multipart(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s) for multipart schema
@@ -394,7 +394,7 @@ def test_form_object_multipart(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -415,14 +415,14 @@ def test_form_object_multipart_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s) for multipart schema
@@ -461,7 +461,7 @@ def test_form_object_multipart_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -482,14 +482,14 @@ def test_form_object_multipart_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s) for multipart schema
@@ -528,7 +528,7 @@ def test_form_object_multipart_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -549,15 +549,15 @@ def _test_form_object_multipart_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -593,7 +593,7 @@ def _test_form_object_multipart_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -626,14 +626,14 @@ def test_form_oneof(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s) for oneOf schema
@@ -687,7 +687,7 @@ def test_form_oneof(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -713,14 +713,14 @@ def test_form_oneof_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s) for oneOf schema
@@ -774,7 +774,7 @@ def test_form_oneof_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -800,14 +800,14 @@ def test_form_oneof_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s) for oneOf schema
@@ -861,7 +861,7 @@ def test_form_oneof_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -887,15 +887,15 @@ def _test_form_oneof_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -941,7 +941,7 @@ def _test_form_oneof_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/header_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/header_api.py
index 9dbee4922feb..85ac32c2e63f 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/header_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/header_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr, field_validator
@@ -49,14 +49,14 @@ def test_header_integer_boolean_string_enums(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test header parameter(s)
@@ -107,7 +107,7 @@ def test_header_integer_boolean_string_enums(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -132,14 +132,14 @@ def test_header_integer_boolean_string_enums_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test header parameter(s)
@@ -190,7 +190,7 @@ def test_header_integer_boolean_string_enums_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -215,14 +215,14 @@ def test_header_integer_boolean_string_enums_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test header parameter(s)
@@ -273,7 +273,7 @@ def test_header_integer_boolean_string_enums_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -298,15 +298,15 @@ def _test_header_integer_boolean_string_enums_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -337,7 +337,7 @@ def _test_header_integer_boolean_string_enums_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/path_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/path_api.py
index e4a07a198eb4..2a51c2849e6c 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/path_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/path_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictInt, StrictStr, field_validator
@@ -47,14 +47,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test path parameter(s)
@@ -102,7 +102,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -126,14 +126,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test path parameter(s)
@@ -181,7 +181,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -205,14 +205,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test path parameter(s)
@@ -260,7 +260,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -284,15 +284,15 @@ def _tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -321,7 +321,7 @@ def _tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/query_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/query_api.py
index ac967a796ab2..5a73bc38b062 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/query_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/query_api.py
@@ -13,12 +13,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from openapi_client.models.pet import Pet
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
@@ -49,14 +49,14 @@ def test_enum_ref_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -98,7 +98,7 @@ def test_enum_ref_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -120,14 +120,14 @@ def test_enum_ref_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -169,7 +169,7 @@ def test_enum_ref_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -191,14 +191,14 @@ def test_enum_ref_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -240,7 +240,7 @@ def test_enum_ref_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -262,15 +262,15 @@ def _test_enum_ref_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -299,7 +299,7 @@ def _test_enum_ref_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -329,14 +329,14 @@ def test_query_datetime_date_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -381,7 +381,7 @@ def test_query_datetime_date_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -404,14 +404,14 @@ def test_query_datetime_date_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -456,7 +456,7 @@ def test_query_datetime_date_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -479,14 +479,14 @@ def test_query_datetime_date_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -531,7 +531,7 @@ def test_query_datetime_date_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -554,15 +554,15 @@ def _test_query_datetime_date_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -613,7 +613,7 @@ def _test_query_datetime_date_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -643,14 +643,14 @@ def test_query_integer_boolean_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -695,7 +695,7 @@ def test_query_integer_boolean_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -718,14 +718,14 @@ def test_query_integer_boolean_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -770,7 +770,7 @@ def test_query_integer_boolean_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -793,14 +793,14 @@ def test_query_integer_boolean_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -845,7 +845,7 @@ def test_query_integer_boolean_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -868,15 +868,15 @@ def _test_query_integer_boolean_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -909,7 +909,7 @@ def _test_query_integer_boolean_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -937,14 +937,14 @@ def test_query_style_deep_object_explode_true_object(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -983,7 +983,7 @@ def test_query_style_deep_object_explode_true_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1004,14 +1004,14 @@ def test_query_style_deep_object_explode_true_object_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1050,7 +1050,7 @@ def test_query_style_deep_object_explode_true_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1071,14 +1071,14 @@ def test_query_style_deep_object_explode_true_object_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1117,7 +1117,7 @@ def test_query_style_deep_object_explode_true_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1138,15 +1138,15 @@ def _test_query_style_deep_object_explode_true_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1171,7 +1171,7 @@ def _test_query_style_deep_object_explode_true_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1199,14 +1199,14 @@ def test_query_style_deep_object_explode_true_object_all_of(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1245,7 +1245,7 @@ def test_query_style_deep_object_explode_true_object_all_of(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1266,14 +1266,14 @@ def test_query_style_deep_object_explode_true_object_all_of_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1312,7 +1312,7 @@ def test_query_style_deep_object_explode_true_object_all_of_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1333,14 +1333,14 @@ def test_query_style_deep_object_explode_true_object_all_of_without_preload_cont
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1379,7 +1379,7 @@ def test_query_style_deep_object_explode_true_object_all_of_without_preload_cont
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1400,15 +1400,15 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1433,7 +1433,7 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1457,18 +1457,18 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
@validate_call
def test_query_style_form_explode_false_array_integer(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1476,7 +1476,7 @@ def test_query_style_form_explode_false_array_integer(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1507,7 +1507,7 @@ def test_query_style_form_explode_false_array_integer(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1524,18 +1524,18 @@ def test_query_style_form_explode_false_array_integer(
@validate_call
def test_query_style_form_explode_false_array_integer_with_http_info(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1543,7 +1543,7 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1574,7 +1574,7 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1591,18 +1591,18 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
@validate_call
def test_query_style_form_explode_false_array_integer_without_preload_content(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1610,7 +1610,7 @@ def test_query_style_form_explode_false_array_integer_without_preload_content(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1641,7 +1641,7 @@ def test_query_style_form_explode_false_array_integer_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1662,16 +1662,16 @@ def _test_query_style_form_explode_false_array_integer_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'query_object': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1696,7 +1696,7 @@ def _test_query_style_form_explode_false_array_integer_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1720,18 +1720,18 @@ def _test_query_style_form_explode_false_array_integer_serialize(
@validate_call
def test_query_style_form_explode_false_array_string(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1739,7 +1739,7 @@ def test_query_style_form_explode_false_array_string(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1770,7 +1770,7 @@ def test_query_style_form_explode_false_array_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1787,18 +1787,18 @@ def test_query_style_form_explode_false_array_string(
@validate_call
def test_query_style_form_explode_false_array_string_with_http_info(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1806,7 +1806,7 @@ def test_query_style_form_explode_false_array_string_with_http_info(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1837,7 +1837,7 @@ def test_query_style_form_explode_false_array_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1854,18 +1854,18 @@ def test_query_style_form_explode_false_array_string_with_http_info(
@validate_call
def test_query_style_form_explode_false_array_string_without_preload_content(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1873,7 +1873,7 @@ def test_query_style_form_explode_false_array_string_without_preload_content(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1904,7 +1904,7 @@ def test_query_style_form_explode_false_array_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1925,16 +1925,16 @@ def _test_query_style_form_explode_false_array_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'query_object': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1959,7 +1959,7 @@ def _test_query_style_form_explode_false_array_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1987,14 +1987,14 @@ def test_query_style_form_explode_true_array_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2033,7 +2033,7 @@ def test_query_style_form_explode_true_array_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2054,14 +2054,14 @@ def test_query_style_form_explode_true_array_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2100,7 +2100,7 @@ def test_query_style_form_explode_true_array_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2121,14 +2121,14 @@ def test_query_style_form_explode_true_array_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2167,7 +2167,7 @@ def test_query_style_form_explode_true_array_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2188,15 +2188,15 @@ def _test_query_style_form_explode_true_array_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2221,7 +2221,7 @@ def _test_query_style_form_explode_true_array_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2249,14 +2249,14 @@ def test_query_style_form_explode_true_object(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2295,7 +2295,7 @@ def test_query_style_form_explode_true_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2316,14 +2316,14 @@ def test_query_style_form_explode_true_object_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2362,7 +2362,7 @@ def test_query_style_form_explode_true_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2383,14 +2383,14 @@ def test_query_style_form_explode_true_object_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2429,7 +2429,7 @@ def test_query_style_form_explode_true_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2450,15 +2450,15 @@ def _test_query_style_form_explode_true_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2483,7 +2483,7 @@ def _test_query_style_form_explode_true_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2511,14 +2511,14 @@ def test_query_style_form_explode_true_object_all_of(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2557,7 +2557,7 @@ def test_query_style_form_explode_true_object_all_of(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2578,14 +2578,14 @@ def test_query_style_form_explode_true_object_all_of_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2624,7 +2624,7 @@ def test_query_style_form_explode_true_object_all_of_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2645,14 +2645,14 @@ def test_query_style_form_explode_true_object_all_of_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2691,7 +2691,7 @@ def test_query_style_form_explode_true_object_all_of_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2712,15 +2712,15 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2745,7 +2745,7 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2770,18 +2770,18 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
def test_query_style_json_serialization_object(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2791,7 +2791,7 @@ def test_query_style_json_serialization_object(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2823,7 +2823,7 @@ def test_query_style_json_serialization_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2841,18 +2841,18 @@ def test_query_style_json_serialization_object(
def test_query_style_json_serialization_object_with_http_info(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2862,7 +2862,7 @@ def test_query_style_json_serialization_object_with_http_info(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2894,7 +2894,7 @@ def test_query_style_json_serialization_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2912,18 +2912,18 @@ def test_query_style_json_serialization_object_with_http_info(
def test_query_style_json_serialization_object_without_preload_content(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2933,7 +2933,7 @@ def test_query_style_json_serialization_object_without_preload_content(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2965,7 +2965,7 @@ def test_query_style_json_serialization_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2987,16 +2987,16 @@ def _test_query_style_json_serialization_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'json_serialized_object_array_ref_string_query': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3025,7 +3025,7 @@ def _test_query_style_json_serialization_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api_client.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api_client.py
index 4b824e431f11..decd2c6213c4 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api_client.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api_client.py
@@ -24,7 +24,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from openapi_client.configuration import Configuration
@@ -41,7 +41,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -287,7 +287,7 @@ def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -435,16 +435,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -479,7 +479,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -509,7 +509,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -543,7 +543,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -576,7 +576,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/configuration.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/configuration.py
index ced011ff8def..03fdce72e33a 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/configuration.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/configuration.py
@@ -17,7 +17,7 @@
from logging import FileHandler
import multiprocessing
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
import urllib3
@@ -29,7 +29,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -122,13 +122,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -202,15 +202,15 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[Union[int, urllib3.util.retry.Retry]] = None,
@@ -355,7 +355,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -561,7 +561,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -577,7 +577,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/bird.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/bird.py
index dc57e5aefb4a..b5c9a1a6857a 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/bird.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/bird.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Bird(BaseModel):
""" # noqa: E501
size: Optional[StrictStr] = None
color: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["size", "color"]
+ __properties: ClassVar[list[str]] = ["size", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bird from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bird from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/category.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/category.py
index 4eb69a30f0b5..c3d278602196 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/category.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/category.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/data_query.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/data_query.py
index 7174dfd0f4cc..2c8012971330 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/data_query.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/data_query.py
@@ -20,9 +20,9 @@
from datetime import datetime
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.query import Query
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class DataQuery(Query):
suffix: Optional[StrictStr] = Field(default=None, description="test suffix")
text: Optional[StrictStr] = Field(default=None, description="Some text containing white spaces")
var_date: Optional[datetime] = Field(default=None, description="A date", alias="date")
- __properties: ClassVar[List[str]] = ["id", "outcomes", "suffix", "text", "date"]
+ __properties: ClassVar[list[str]] = ["id", "outcomes", "suffix", "text", "date"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DataQuery from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DataQuery from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/default_value.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/default_value.py
index a6139f9d813f..be6a0a7b6469 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/default_value.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/default_value.py
@@ -19,9 +19,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.string_enum_ref import StringEnumRef
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,15 +29,15 @@ class DefaultValue(BaseModel):
"""
to test the default value of properties
""" # noqa: E501
- array_string_enum_ref_default: Optional[List[StringEnumRef]] = None
- array_string_enum_default: Optional[List[StrictStr]] = None
- array_string_default: Optional[List[StrictStr]] = None
- array_integer_default: Optional[List[StrictInt]] = None
- array_string: Optional[List[StrictStr]] = None
- array_string_nullable: Optional[List[StrictStr]] = None
- array_string_extension_nullable: Optional[List[StrictStr]] = None
+ array_string_enum_ref_default: Optional[list[StringEnumRef]] = None
+ array_string_enum_default: Optional[list[StrictStr]] = None
+ array_string_default: Optional[list[StrictStr]] = None
+ array_integer_default: Optional[list[StrictInt]] = None
+ array_string: Optional[list[StrictStr]] = None
+ array_string_nullable: Optional[list[StrictStr]] = None
+ array_string_extension_nullable: Optional[list[StrictStr]] = None
string_nullable: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["array_string_enum_ref_default", "array_string_enum_default", "array_string_default", "array_integer_default", "array_string", "array_string_nullable", "array_string_extension_nullable", "string_nullable"]
+ __properties: ClassVar[list[str]] = ["array_string_enum_ref_default", "array_string_enum_default", "array_string_default", "array_integer_default", "array_string", "array_string_nullable", "array_string_extension_nullable", "string_nullable"]
@field_validator('array_string_enum_default')
def array_string_enum_default_validate_enum(cls, value):
@@ -71,7 +71,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -107,7 +107,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/number_properties_only.py
index 7798675f9ad7..2ce11058b5b9 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/number_properties_only.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/number_properties_only.py
@@ -19,9 +19,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class NumberPropertiesOnly(BaseModel):
number: Optional[Union[StrictFloat, StrictInt]] = None
var_float: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="float")
double: Optional[Union[Annotated[float, Field(le=50.2, strict=True, ge=0.8)], Annotated[int, Field(le=50, strict=True, ge=1)]]] = None
- __properties: ClassVar[List[str]] = ["number", "float", "double"]
+ __properties: ClassVar[list[str]] = ["number", "float", "double"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberPropertiesOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberPropertiesOnly from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/pet.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/pet.py
index 17369bc2e343..1d46f83959bc 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/pet.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/pet.py
@@ -19,10 +19,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.category import Category
from openapi_client.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,10 +33,10 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
name: StrictStr
category: Optional[Category] = None
- photo_urls: List[StrictStr] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: list[StrictStr] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- __properties: ClassVar[List[str]] = ["id", "name", "category", "photoUrls", "tags", "status"]
+ __properties: ClassVar[list[str]] = ["id", "name", "category", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -69,7 +69,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/query.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/query.py
index 2114ca55db44..344da3c251b7 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/query.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/query.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Query(BaseModel):
Query
""" # noqa: E501
id: Optional[StrictInt] = Field(default=None, description="Query")
- outcomes: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["id", "outcomes"]
+ outcomes: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["id", "outcomes"]
@field_validator('outcomes')
def outcomes_validate_enum(cls, value):
@@ -64,7 +64,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Query from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Self]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Self]:
"""Create an instance of Query from a dict"""
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/tag.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/tag.py
index 23a5e7148c50..5a6d6c357c28 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/tag.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/tag.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py
index 86365217f05b..0a5cd63fbdc4 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class TestFormObjectMultipartRequestMarker(BaseModel):
TestFormObjectMultipartRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestFormObjectMultipartRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestFormObjectMultipartRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
index 1d48dcc12b80..72816b718270 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter(BaseMod
color: Optional[StrictStr] = None
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["size", "color", "id", "name"]
+ __properties: ClassVar[list[str]] = ["size", "color", "id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
index c8a9f0b889e0..369e30660b8c 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter(BaseModel):
"""
TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
""" # noqa: E501
- values: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["values"]
+ values: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["values"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/BodyApi.md b/samples/client/echo_api/python-pydantic-v1/docs/BodyApi.md
index 0f22b6b2a6d2..b0c9c65fee03 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/BodyApi.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/BodyApi.md
@@ -171,7 +171,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.BodyApi(api_client)
- files = None # List[bytearray] |
+ files = None # list[bytearray] |
try:
# Test array of binary in multipart mime
@@ -188,7 +188,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **files** | **List[bytearray]**| |
+ **files** | **list[bytearray]**| |
### Return type
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/DefaultValue.md b/samples/client/echo_api/python-pydantic-v1/docs/DefaultValue.md
index b2a8cdfd6216..12d331beb912 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/DefaultValue.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/DefaultValue.md
@@ -5,13 +5,13 @@ to test the default value of properties
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_string_enum_ref_default** | [**List[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
-**array_string_enum_default** | **List[str]** | | [optional] [default to ["success","failure"]]
-**array_string_default** | **List[str]** | | [optional] [default to ["failure","skipped"]]
-**array_integer_default** | **List[int]** | | [optional] [default to [1,3]]
-**array_string** | **List[str]** | | [optional]
-**array_string_nullable** | **List[str]** | | [optional]
-**array_string_extension_nullable** | **List[str]** | | [optional]
+**array_string_enum_ref_default** | [**list[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
+**array_string_enum_default** | **list[str]** | | [optional] [default to ["success","failure"]]
+**array_string_default** | **list[str]** | | [optional] [default to ["failure","skipped"]]
+**array_integer_default** | **list[int]** | | [optional] [default to [1,3]]
+**array_string** | **list[str]** | | [optional]
+**array_string_nullable** | **list[str]** | | [optional]
+**array_string_extension_nullable** | **list[str]** | | [optional]
**string_nullable** | **str** | | [optional]
## Example
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/Pet.md b/samples/client/echo_api/python-pydantic-v1/docs/Pet.md
index 82135416b79d..98544dbb7c37 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/Pet.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/Pet.md
@@ -7,8 +7,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**name** | **str** | |
**category** | [**Category**](Category.md) | | [optional]
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/Query.md b/samples/client/echo_api/python-pydantic-v1/docs/Query.md
index ff05faf95865..f23d86dfeedb 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/Query.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/Query.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **int** | Query | [optional]
-**outcomes** | **List[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
+**outcomes** | **list[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
## Example
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/QueryApi.md b/samples/client/echo_api/python-pydantic-v1/docs/QueryApi.md
index 88a27b10186a..3c693d9f0fe7 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/QueryApi.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/QueryApi.md
@@ -386,7 +386,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = [56] # List[int] | (optional)
+ query_object = [56] # list[int] | (optional)
try:
# Test query parameter(s)
@@ -403,7 +403,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[int]**](int.md)| | [optional]
+ **query_object** | [**list[int]**](int.md)| | [optional]
### Return type
@@ -452,7 +452,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = ['query_object_example'] # List[str] | (optional)
+ query_object = ['query_object_example'] # list[str] | (optional)
try:
# Test query parameter(s)
@@ -469,7 +469,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[str]**](str.md)| | [optional]
+ **query_object** | [**list[str]**](str.md)| | [optional]
### Return type
@@ -720,7 +720,7 @@ with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
json_serialized_object_ref_string_query = openapi_client.Pet() # Pet | (optional)
- json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # List[Pet] | (optional)
+ json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # list[Pet] | (optional)
try:
# Test query parameter(s)
@@ -738,7 +738,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**json_serialized_object_ref_string_query** | [**Pet**](.md)| | [optional]
- **json_serialized_object_array_ref_string_query** | [**List[Pet]**](Pet.md)| | [optional]
+ **json_serialized_object_array_ref_string_query** | [**list[Pet]**](Pet.md)| | [optional]
### Return type
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md b/samples/client/echo_api/python-pydantic-v1/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
index b087d3a3774f..cc60379846b5 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**values** | **List[str]** | | [optional]
+**values** | **list[str]** | | [optional]
## Example
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/body_api.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/body_api.py
index 73a283c02b1a..6d7700d0f5b7 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/body_api.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/body_api.py
@@ -22,7 +22,7 @@
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictStr, conlist
-from typing import Any, Dict, Optional, Union
+from typing import Any, Optional, Union
from openapi_client.models.pet import Pet
from openapi_client.models.string_enum_ref import StringEnumRef
@@ -344,7 +344,7 @@ def test_body_multipart_formdata_array_of_binary(self, files : conlist(Union[Str
>>> result = thread.get()
:param files: (required)
- :type files: List[bytearray]
+ :type files: list[bytearray]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -374,7 +374,7 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(self, files : co
>>> result = thread.get()
:param files: (required)
- :type files: List[bytearray]
+ :type files: list[bytearray]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -775,7 +775,7 @@ def test_echo_body_all_of_pet_with_http_info(self, pet : Annotated[Optional[Pet]
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def test_echo_body_free_form_object_response_string(self, body : Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None, **kwargs) -> str: # noqa: E501
+ def test_echo_body_free_form_object_response_string(self, body : Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None, **kwargs) -> str: # noqa: E501
"""Test free form object # noqa: E501
Test free form object # noqa: E501
@@ -805,7 +805,7 @@ def test_echo_body_free_form_object_response_string(self, body : Annotated[Optio
return self.test_echo_body_free_form_object_response_string_with_http_info(body, **kwargs) # noqa: E501
@validate_arguments
- def test_echo_body_free_form_object_response_string_with_http_info(self, body : Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None, **kwargs) -> ApiResponse: # noqa: E501
+ def test_echo_body_free_form_object_response_string_with_http_info(self, body : Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None, **kwargs) -> ApiResponse: # noqa: E501
"""Test free form object # noqa: E501
Test free form object # noqa: E501
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/query_api.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/query_api.py
index e6b9a6e20337..aa18d43e4199 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/query_api.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/query_api.py
@@ -807,7 +807,7 @@ def test_query_style_form_explode_false_array_integer(self, query_object : Optio
>>> result = thread.get()
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -837,7 +837,7 @@ def test_query_style_form_explode_false_array_integer_with_http_info(self, query
>>> result = thread.get()
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -948,7 +948,7 @@ def test_query_style_form_explode_false_array_string(self, query_object : Option
>>> result = thread.get()
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -978,7 +978,7 @@ def test_query_style_form_explode_false_array_string_with_http_info(self, query_
>>> result = thread.get()
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -1511,7 +1511,7 @@ def test_query_style_json_serialization_object(self, json_serialized_object_ref_
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -1543,7 +1543,7 @@ def test_query_style_json_serialization_object_with_http_info(self, json_seriali
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/api_client.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/api_client.py
index cceab3d92f74..a9a1b072ed8d 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/api_client.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/api_client.py
@@ -338,13 +338,13 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- sub_kls = re.match(r'List\[(.*)]', klass).group(1)
+ if klass.startswith('list['):
+ sub_kls = re.match(r'list\[(.*)]', klass).group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- sub_kls = re.match(r'Dict\[([^,]*), (.*)]', klass).group(2)
+ if klass.startswith('dict['):
+ sub_kls = re.match(r'dict\[([^,]*), (.*)]', klass).group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/api_response.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/api_response.py
index a0b62b95246c..0ce9c905789f 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/api_response.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/api_response.py
@@ -1,7 +1,7 @@
"""API response object."""
from __future__ import annotations
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictInt, StrictStr
class ApiResponse:
@@ -10,7 +10,7 @@ class ApiResponse:
"""
status_code: Optional[StrictInt] = Field(None, description="HTTP status code")
- headers: Optional[Dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
+ headers: Optional[dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
data: Optional[Any] = Field(None, description="Deserialized data given the data type")
raw_data: Optional[Any] = Field(None, description="Raw data (HTTP response body)")
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py
index e038747ba4eb..100d31e5ced2 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py
@@ -19,7 +19,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, StrictInt, StrictStr, conlist, validator
from openapi_client.models.string_enum_ref import StringEnumRef
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py
index 1d26ea28a588..6d1dc78a6313 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py
@@ -19,7 +19,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr, conlist, validator
from openapi_client.models.category import Category
from openapi_client.models.tag import Tag
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/query.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/query.py
index b86d0fc09f85..d80d981f9079 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/query.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/query.py
@@ -19,7 +19,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr, conlist, validator
class Query(BaseModel):
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
index 1bff80a6df1c..24a102fcca95 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
@@ -19,7 +19,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, StrictStr, conlist
class TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter(BaseModel):
diff --git a/samples/client/echo_api/python/docs/BodyApi.md b/samples/client/echo_api/python/docs/BodyApi.md
index 86be9cc416c4..aab0c5e74db9 100644
--- a/samples/client/echo_api/python/docs/BodyApi.md
+++ b/samples/client/echo_api/python/docs/BodyApi.md
@@ -172,7 +172,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.BodyApi(api_client)
- files = None # List[bytes] |
+ files = None # list[bytes] |
try:
# Test array of binary in multipart mime
@@ -190,7 +190,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **files** | **List[bytes]**| |
+ **files** | **list[bytes]**| |
### Return type
diff --git a/samples/client/echo_api/python/docs/DefaultValue.md b/samples/client/echo_api/python/docs/DefaultValue.md
index 7c1668c0d6c6..8459d262b344 100644
--- a/samples/client/echo_api/python/docs/DefaultValue.md
+++ b/samples/client/echo_api/python/docs/DefaultValue.md
@@ -6,13 +6,13 @@ to test the default value of properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_string_enum_ref_default** | [**List[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
-**array_string_enum_default** | **List[str]** | | [optional] [default to ["success","failure"]]
-**array_string_default** | **List[str]** | | [optional] [default to ["failure","skipped"]]
-**array_integer_default** | **List[int]** | | [optional] [default to [1,3]]
-**array_string** | **List[str]** | | [optional]
-**array_string_nullable** | **List[str]** | | [optional]
-**array_string_extension_nullable** | **List[str]** | | [optional]
+**array_string_enum_ref_default** | [**list[StringEnumRef]**](StringEnumRef.md) | | [optional] [default to ["success","failure"]]
+**array_string_enum_default** | **list[str]** | | [optional] [default to ["success","failure"]]
+**array_string_default** | **list[str]** | | [optional] [default to ["failure","skipped"]]
+**array_integer_default** | **list[int]** | | [optional] [default to [1,3]]
+**array_string** | **list[str]** | | [optional]
+**array_string_nullable** | **list[str]** | | [optional]
+**array_string_extension_nullable** | **list[str]** | | [optional]
**string_nullable** | **str** | | [optional]
## Example
diff --git a/samples/client/echo_api/python/docs/Pet.md b/samples/client/echo_api/python/docs/Pet.md
index 99b4bf3ab010..ee8124b0063d 100644
--- a/samples/client/echo_api/python/docs/Pet.md
+++ b/samples/client/echo_api/python/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**name** | **str** | |
**category** | [**Category**](Category.md) | | [optional]
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/client/echo_api/python/docs/Query.md b/samples/client/echo_api/python/docs/Query.md
index d39693eb5b93..cc247b24b821 100644
--- a/samples/client/echo_api/python/docs/Query.md
+++ b/samples/client/echo_api/python/docs/Query.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **int** | Query | [optional]
-**outcomes** | **List[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
+**outcomes** | **list[str]** | | [optional] [default to ["SUCCESS","FAILURE"]]
## Example
diff --git a/samples/client/echo_api/python/docs/QueryApi.md b/samples/client/echo_api/python/docs/QueryApi.md
index dc1a241c15c2..1b28ad01380e 100644
--- a/samples/client/echo_api/python/docs/QueryApi.md
+++ b/samples/client/echo_api/python/docs/QueryApi.md
@@ -390,7 +390,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = [56] # List[int] | (optional)
+ query_object = [56] # list[int] | (optional)
try:
# Test query parameter(s)
@@ -408,7 +408,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[int]**](int.md)| | [optional]
+ **query_object** | [**list[int]**](int.md)| | [optional]
### Return type
@@ -457,7 +457,7 @@ configuration = openapi_client.Configuration(
with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
- query_object = ['query_object_example'] # List[str] | (optional)
+ query_object = ['query_object_example'] # list[str] | (optional)
try:
# Test query parameter(s)
@@ -475,7 +475,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **query_object** | [**List[str]**](str.md)| | [optional]
+ **query_object** | [**list[str]**](str.md)| | [optional]
### Return type
@@ -729,7 +729,7 @@ with openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = openapi_client.QueryApi(api_client)
json_serialized_object_ref_string_query = openapi_client.Pet() # Pet | (optional)
- json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # List[Pet] | (optional)
+ json_serialized_object_array_ref_string_query = [openapi_client.Pet()] # list[Pet] | (optional)
try:
# Test query parameter(s)
@@ -748,7 +748,7 @@ with openapi_client.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**json_serialized_object_ref_string_query** | [**Pet**](.md)| | [optional]
- **json_serialized_object_array_ref_string_query** | [**List[Pet]**](Pet.md)| | [optional]
+ **json_serialized_object_array_ref_string_query** | [**list[Pet]**](Pet.md)| | [optional]
### Return type
diff --git a/samples/client/echo_api/python/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md b/samples/client/echo_api/python/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
index 846a0941a09c..2c861924ec43 100644
--- a/samples/client/echo_api/python/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
+++ b/samples/client/echo_api/python/docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**values** | **List[str]** | | [optional]
+**values** | **list[str]** | | [optional]
## Example
diff --git a/samples/client/echo_api/python/openapi_client/api/auth_api.py b/samples/client/echo_api/python/openapi_client/api/auth_api.py
index 3ad40309ce6f..47ccb190b020 100644
--- a/samples/client/echo_api/python/openapi_client/api/auth_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/auth_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictStr
@@ -42,14 +42,14 @@ def test_auth_http_basic(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""To test HTTP basic authentication
@@ -85,7 +85,7 @@ def test_auth_http_basic(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -105,14 +105,14 @@ def test_auth_http_basic_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""To test HTTP basic authentication
@@ -148,7 +148,7 @@ def test_auth_http_basic_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -168,14 +168,14 @@ def test_auth_http_basic_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test HTTP basic authentication
@@ -211,7 +211,7 @@ def test_auth_http_basic_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -231,15 +231,15 @@ def _test_auth_http_basic_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -260,7 +260,7 @@ def _test_auth_http_basic_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_auth'
]
@@ -288,14 +288,14 @@ def test_auth_http_bearer(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""To test HTTP bearer authentication
@@ -331,7 +331,7 @@ def test_auth_http_bearer(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -351,14 +351,14 @@ def test_auth_http_bearer_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""To test HTTP bearer authentication
@@ -394,7 +394,7 @@ def test_auth_http_bearer_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -414,14 +414,14 @@ def test_auth_http_bearer_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test HTTP bearer authentication
@@ -457,7 +457,7 @@ def test_auth_http_bearer_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -477,15 +477,15 @@ def _test_auth_http_bearer_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -506,7 +506,7 @@ def _test_auth_http_bearer_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_bearer_auth'
]
diff --git a/samples/client/echo_api/python/openapi_client/api/body_api.py b/samples/client/echo_api/python/openapi_client/api/body_api.py
index c4b05d54f131..f5144333c166 100644
--- a/samples/client/echo_api/python/openapi_client/api/body_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/body_api.py
@@ -13,11 +13,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictStr
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from openapi_client.models.pet import Pet
from openapi_client.models.string_enum_ref import StringEnumRef
@@ -47,14 +47,14 @@ def test_binary_gif(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""Test binary (gif) response body
@@ -90,7 +90,7 @@ def test_binary_gif(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -110,14 +110,14 @@ def test_binary_gif_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""Test binary (gif) response body
@@ -153,7 +153,7 @@ def test_binary_gif_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -173,14 +173,14 @@ def test_binary_gif_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test binary (gif) response body
@@ -216,7 +216,7 @@ def test_binary_gif_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -236,15 +236,15 @@ def _test_binary_gif_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -265,7 +265,7 @@ def _test_binary_gif_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -289,18 +289,18 @@ def _test_binary_gif_serialize(
@validate_call
def test_body_application_octetstream_binary(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test body parameter(s)
@@ -339,7 +339,7 @@ def test_body_application_octetstream_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -356,18 +356,18 @@ def test_body_application_octetstream_binary(
@validate_call
def test_body_application_octetstream_binary_with_http_info(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test body parameter(s)
@@ -406,7 +406,7 @@ def test_body_application_octetstream_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -423,18 +423,18 @@ def test_body_application_octetstream_binary_with_http_info(
@validate_call
def test_body_application_octetstream_binary_without_preload_content(
self,
- body: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ body: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -473,7 +473,7 @@ def test_body_application_octetstream_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -494,15 +494,15 @@ def _test_body_application_octetstream_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -546,7 +546,7 @@ def _test_body_application_octetstream_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -570,18 +570,18 @@ def _test_body_application_octetstream_binary_serialize(
@validate_call
def test_body_multipart_formdata_array_of_binary(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test array of binary in multipart mime
@@ -589,7 +589,7 @@ def test_body_multipart_formdata_array_of_binary(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -620,7 +620,7 @@ def test_body_multipart_formdata_array_of_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -637,18 +637,18 @@ def test_body_multipart_formdata_array_of_binary(
@validate_call
def test_body_multipart_formdata_array_of_binary_with_http_info(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test array of binary in multipart mime
@@ -656,7 +656,7 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -687,7 +687,7 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -704,18 +704,18 @@ def test_body_multipart_formdata_array_of_binary_with_http_info(
@validate_call
def test_body_multipart_formdata_array_of_binary_without_preload_content(
self,
- files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
+ files: list[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test array of binary in multipart mime
@@ -723,7 +723,7 @@ def test_body_multipart_formdata_array_of_binary_without_preload_content(
Test array of binary in multipart mime
:param files: (required)
- :type files: List[bytes]
+ :type files: list[bytes]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -754,7 +754,7 @@ def test_body_multipart_formdata_array_of_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -775,16 +775,16 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'files': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -820,7 +820,7 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -844,18 +844,18 @@ def _test_body_multipart_formdata_array_of_binary_serialize(
@validate_call
def test_body_multipart_formdata_single_binary(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test single binary in multipart mime
@@ -894,7 +894,7 @@ def test_body_multipart_formdata_single_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -911,18 +911,18 @@ def test_body_multipart_formdata_single_binary(
@validate_call
def test_body_multipart_formdata_single_binary_with_http_info(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test single binary in multipart mime
@@ -961,7 +961,7 @@ def test_body_multipart_formdata_single_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -978,18 +978,18 @@ def test_body_multipart_formdata_single_binary_with_http_info(
@validate_call
def test_body_multipart_formdata_single_binary_without_preload_content(
self,
- my_file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
+ my_file: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test single binary in multipart mime
@@ -1028,7 +1028,7 @@ def test_body_multipart_formdata_single_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1049,15 +1049,15 @@ def _test_body_multipart_formdata_single_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1093,7 +1093,7 @@ def _test_body_multipart_formdata_single_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1121,14 +1121,14 @@ def test_echo_body_all_of_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Test body parameter(s)
@@ -1167,7 +1167,7 @@ def test_echo_body_all_of_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1188,14 +1188,14 @@ def test_echo_body_all_of_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Test body parameter(s)
@@ -1234,7 +1234,7 @@ def test_echo_body_all_of_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1255,14 +1255,14 @@ def test_echo_body_all_of_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -1301,7 +1301,7 @@ def test_echo_body_all_of_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1322,15 +1322,15 @@ def _test_echo_body_all_of_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1366,7 +1366,7 @@ def _test_echo_body_all_of_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1390,18 +1390,18 @@ def _test_echo_body_all_of_pet_serialize(
@validate_call
def test_echo_body_free_form_object_response_string(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test free form object
@@ -1440,7 +1440,7 @@ def test_echo_body_free_form_object_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1457,18 +1457,18 @@ def test_echo_body_free_form_object_response_string(
@validate_call
def test_echo_body_free_form_object_response_string_with_http_info(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test free form object
@@ -1507,7 +1507,7 @@ def test_echo_body_free_form_object_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1524,18 +1524,18 @@ def test_echo_body_free_form_object_response_string_with_http_info(
@validate_call
def test_echo_body_free_form_object_response_string_without_preload_content(
self,
- body: Annotated[Optional[Dict[str, Any]], Field(description="Free form object")] = None,
+ body: Annotated[Optional[dict[str, Any]], Field(description="Free form object")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test free form object
@@ -1574,7 +1574,7 @@ def test_echo_body_free_form_object_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1595,15 +1595,15 @@ def _test_echo_body_free_form_object_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1639,7 +1639,7 @@ def _test_echo_body_free_form_object_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1667,14 +1667,14 @@ def test_echo_body_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Test body parameter(s)
@@ -1713,7 +1713,7 @@ def test_echo_body_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1734,14 +1734,14 @@ def test_echo_body_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Test body parameter(s)
@@ -1780,7 +1780,7 @@ def test_echo_body_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1801,14 +1801,14 @@ def test_echo_body_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test body parameter(s)
@@ -1847,7 +1847,7 @@ def test_echo_body_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
}
response_data = self.api_client.call_api(
@@ -1868,15 +1868,15 @@ def _test_echo_body_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1912,7 +1912,7 @@ def _test_echo_body_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1940,14 +1940,14 @@ def test_echo_body_pet_response_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test empty response body
@@ -1986,7 +1986,7 @@ def test_echo_body_pet_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2007,14 +2007,14 @@ def test_echo_body_pet_response_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test empty response body
@@ -2053,7 +2053,7 @@ def test_echo_body_pet_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2074,14 +2074,14 @@ def test_echo_body_pet_response_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test empty response body
@@ -2120,7 +2120,7 @@ def test_echo_body_pet_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2141,15 +2141,15 @@ def _test_echo_body_pet_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2185,7 +2185,7 @@ def _test_echo_body_pet_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2213,14 +2213,14 @@ def test_echo_body_string_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> StringEnumRef:
"""Test string enum response body
@@ -2259,7 +2259,7 @@ def test_echo_body_string_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2280,14 +2280,14 @@ def test_echo_body_string_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[StringEnumRef]:
"""Test string enum response body
@@ -2326,7 +2326,7 @@ def test_echo_body_string_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2347,14 +2347,14 @@ def test_echo_body_string_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test string enum response body
@@ -2393,7 +2393,7 @@ def test_echo_body_string_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "StringEnumRef",
}
response_data = self.api_client.call_api(
@@ -2414,15 +2414,15 @@ def _test_echo_body_string_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2458,7 +2458,7 @@ def _test_echo_body_string_enum_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2486,14 +2486,14 @@ def test_echo_body_tag_response_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test empty json (request body)
@@ -2532,7 +2532,7 @@ def test_echo_body_tag_response_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2553,14 +2553,14 @@ def test_echo_body_tag_response_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test empty json (request body)
@@ -2599,7 +2599,7 @@ def test_echo_body_tag_response_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2620,14 +2620,14 @@ def test_echo_body_tag_response_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test empty json (request body)
@@ -2666,7 +2666,7 @@ def test_echo_body_tag_response_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2687,15 +2687,15 @@ def _test_echo_body_tag_response_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2731,7 +2731,7 @@ def _test_echo_body_tag_response_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python/openapi_client/api/form_api.py b/samples/client/echo_api/python/openapi_client/api/form_api.py
index e4e3ddffa3ac..69d966602e86 100644
--- a/samples/client/echo_api/python/openapi_client/api/form_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/form_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr
@@ -47,14 +47,14 @@ def test_form_integer_boolean_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s)
@@ -99,7 +99,7 @@ def test_form_integer_boolean_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -122,14 +122,14 @@ def test_form_integer_boolean_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s)
@@ -174,7 +174,7 @@ def test_form_integer_boolean_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -197,14 +197,14 @@ def test_form_integer_boolean_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s)
@@ -249,7 +249,7 @@ def test_form_integer_boolean_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -272,15 +272,15 @@ def _test_form_integer_boolean_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -320,7 +320,7 @@ def _test_form_integer_boolean_string_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -348,14 +348,14 @@ def test_form_object_multipart(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s) for multipart schema
@@ -394,7 +394,7 @@ def test_form_object_multipart(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -415,14 +415,14 @@ def test_form_object_multipart_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s) for multipart schema
@@ -461,7 +461,7 @@ def test_form_object_multipart_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -482,14 +482,14 @@ def test_form_object_multipart_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s) for multipart schema
@@ -528,7 +528,7 @@ def test_form_object_multipart_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -549,15 +549,15 @@ def _test_form_object_multipart_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -593,7 +593,7 @@ def _test_form_object_multipart_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -626,14 +626,14 @@ def test_form_oneof(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test form parameter(s) for oneOf schema
@@ -687,7 +687,7 @@ def test_form_oneof(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -713,14 +713,14 @@ def test_form_oneof_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test form parameter(s) for oneOf schema
@@ -774,7 +774,7 @@ def test_form_oneof_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -800,14 +800,14 @@ def test_form_oneof_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test form parameter(s) for oneOf schema
@@ -861,7 +861,7 @@ def test_form_oneof_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -887,15 +887,15 @@ def _test_form_oneof_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -941,7 +941,7 @@ def _test_form_oneof_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python/openapi_client/api/header_api.py b/samples/client/echo_api/python/openapi_client/api/header_api.py
index 9dbee4922feb..85ac32c2e63f 100644
--- a/samples/client/echo_api/python/openapi_client/api/header_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/header_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr, field_validator
@@ -49,14 +49,14 @@ def test_header_integer_boolean_string_enums(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test header parameter(s)
@@ -107,7 +107,7 @@ def test_header_integer_boolean_string_enums(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -132,14 +132,14 @@ def test_header_integer_boolean_string_enums_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test header parameter(s)
@@ -190,7 +190,7 @@ def test_header_integer_boolean_string_enums_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -215,14 +215,14 @@ def test_header_integer_boolean_string_enums_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test header parameter(s)
@@ -273,7 +273,7 @@ def test_header_integer_boolean_string_enums_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -298,15 +298,15 @@ def _test_header_integer_boolean_string_enums_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -337,7 +337,7 @@ def _test_header_integer_boolean_string_enums_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python/openapi_client/api/path_api.py b/samples/client/echo_api/python/openapi_client/api/path_api.py
index e4a07a198eb4..2a51c2849e6c 100644
--- a/samples/client/echo_api/python/openapi_client/api/path_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/path_api.py
@@ -13,7 +13,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import StrictInt, StrictStr, field_validator
@@ -47,14 +47,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test path parameter(s)
@@ -102,7 +102,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -126,14 +126,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test path parameter(s)
@@ -181,7 +181,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -205,14 +205,14 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test path parameter(s)
@@ -260,7 +260,7 @@ def tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_e
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -284,15 +284,15 @@ def _tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -321,7 +321,7 @@ def _tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python/openapi_client/api/query_api.py b/samples/client/echo_api/python/openapi_client/api/query_api.py
index ac967a796ab2..5a73bc38b062 100644
--- a/samples/client/echo_api/python/openapi_client/api/query_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/query_api.py
@@ -13,12 +13,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from openapi_client.models.pet import Pet
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
@@ -49,14 +49,14 @@ def test_enum_ref_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -98,7 +98,7 @@ def test_enum_ref_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -120,14 +120,14 @@ def test_enum_ref_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -169,7 +169,7 @@ def test_enum_ref_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -191,14 +191,14 @@ def test_enum_ref_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -240,7 +240,7 @@ def test_enum_ref_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -262,15 +262,15 @@ def _test_enum_ref_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -299,7 +299,7 @@ def _test_enum_ref_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -329,14 +329,14 @@ def test_query_datetime_date_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -381,7 +381,7 @@ def test_query_datetime_date_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -404,14 +404,14 @@ def test_query_datetime_date_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -456,7 +456,7 @@ def test_query_datetime_date_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -479,14 +479,14 @@ def test_query_datetime_date_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -531,7 +531,7 @@ def test_query_datetime_date_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -554,15 +554,15 @@ def _test_query_datetime_date_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -613,7 +613,7 @@ def _test_query_datetime_date_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -643,14 +643,14 @@ def test_query_integer_boolean_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -695,7 +695,7 @@ def test_query_integer_boolean_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -718,14 +718,14 @@ def test_query_integer_boolean_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -770,7 +770,7 @@ def test_query_integer_boolean_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -793,14 +793,14 @@ def test_query_integer_boolean_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -845,7 +845,7 @@ def test_query_integer_boolean_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -868,15 +868,15 @@ def _test_query_integer_boolean_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -909,7 +909,7 @@ def _test_query_integer_boolean_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -937,14 +937,14 @@ def test_query_style_deep_object_explode_true_object(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -983,7 +983,7 @@ def test_query_style_deep_object_explode_true_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1004,14 +1004,14 @@ def test_query_style_deep_object_explode_true_object_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1050,7 +1050,7 @@ def test_query_style_deep_object_explode_true_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1071,14 +1071,14 @@ def test_query_style_deep_object_explode_true_object_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1117,7 +1117,7 @@ def test_query_style_deep_object_explode_true_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1138,15 +1138,15 @@ def _test_query_style_deep_object_explode_true_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1171,7 +1171,7 @@ def _test_query_style_deep_object_explode_true_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1199,14 +1199,14 @@ def test_query_style_deep_object_explode_true_object_all_of(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1245,7 +1245,7 @@ def test_query_style_deep_object_explode_true_object_all_of(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1266,14 +1266,14 @@ def test_query_style_deep_object_explode_true_object_all_of_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1312,7 +1312,7 @@ def test_query_style_deep_object_explode_true_object_all_of_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1333,14 +1333,14 @@ def test_query_style_deep_object_explode_true_object_all_of_without_preload_cont
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1379,7 +1379,7 @@ def test_query_style_deep_object_explode_true_object_all_of_without_preload_cont
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1400,15 +1400,15 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1433,7 +1433,7 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1457,18 +1457,18 @@ def _test_query_style_deep_object_explode_true_object_all_of_serialize(
@validate_call
def test_query_style_form_explode_false_array_integer(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1476,7 +1476,7 @@ def test_query_style_form_explode_false_array_integer(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1507,7 +1507,7 @@ def test_query_style_form_explode_false_array_integer(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1524,18 +1524,18 @@ def test_query_style_form_explode_false_array_integer(
@validate_call
def test_query_style_form_explode_false_array_integer_with_http_info(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1543,7 +1543,7 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1574,7 +1574,7 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1591,18 +1591,18 @@ def test_query_style_form_explode_false_array_integer_with_http_info(
@validate_call
def test_query_style_form_explode_false_array_integer_without_preload_content(
self,
- query_object: Optional[List[StrictInt]] = None,
+ query_object: Optional[list[StrictInt]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1610,7 +1610,7 @@ def test_query_style_form_explode_false_array_integer_without_preload_content(
Test query parameter(s)
:param query_object:
- :type query_object: List[int]
+ :type query_object: list[int]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1641,7 +1641,7 @@ def test_query_style_form_explode_false_array_integer_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1662,16 +1662,16 @@ def _test_query_style_form_explode_false_array_integer_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'query_object': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1696,7 +1696,7 @@ def _test_query_style_form_explode_false_array_integer_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1720,18 +1720,18 @@ def _test_query_style_form_explode_false_array_integer_serialize(
@validate_call
def test_query_style_form_explode_false_array_string(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -1739,7 +1739,7 @@ def test_query_style_form_explode_false_array_string(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1770,7 +1770,7 @@ def test_query_style_form_explode_false_array_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1787,18 +1787,18 @@ def test_query_style_form_explode_false_array_string(
@validate_call
def test_query_style_form_explode_false_array_string_with_http_info(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -1806,7 +1806,7 @@ def test_query_style_form_explode_false_array_string_with_http_info(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1837,7 +1837,7 @@ def test_query_style_form_explode_false_array_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1854,18 +1854,18 @@ def test_query_style_form_explode_false_array_string_with_http_info(
@validate_call
def test_query_style_form_explode_false_array_string_without_preload_content(
self,
- query_object: Optional[List[StrictStr]] = None,
+ query_object: Optional[list[StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -1873,7 +1873,7 @@ def test_query_style_form_explode_false_array_string_without_preload_content(
Test query parameter(s)
:param query_object:
- :type query_object: List[str]
+ :type query_object: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1904,7 +1904,7 @@ def test_query_style_form_explode_false_array_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -1925,16 +1925,16 @@ def _test_query_style_form_explode_false_array_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'query_object': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1959,7 +1959,7 @@ def _test_query_style_form_explode_false_array_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1987,14 +1987,14 @@ def test_query_style_form_explode_true_array_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2033,7 +2033,7 @@ def test_query_style_form_explode_true_array_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2054,14 +2054,14 @@ def test_query_style_form_explode_true_array_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2100,7 +2100,7 @@ def test_query_style_form_explode_true_array_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2121,14 +2121,14 @@ def test_query_style_form_explode_true_array_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2167,7 +2167,7 @@ def test_query_style_form_explode_true_array_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2188,15 +2188,15 @@ def _test_query_style_form_explode_true_array_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2221,7 +2221,7 @@ def _test_query_style_form_explode_true_array_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2249,14 +2249,14 @@ def test_query_style_form_explode_true_object(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2295,7 +2295,7 @@ def test_query_style_form_explode_true_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2316,14 +2316,14 @@ def test_query_style_form_explode_true_object_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2362,7 +2362,7 @@ def test_query_style_form_explode_true_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2383,14 +2383,14 @@ def test_query_style_form_explode_true_object_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2429,7 +2429,7 @@ def test_query_style_form_explode_true_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2450,15 +2450,15 @@ def _test_query_style_form_explode_true_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2483,7 +2483,7 @@ def _test_query_style_form_explode_true_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2511,14 +2511,14 @@ def test_query_style_form_explode_true_object_all_of(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2557,7 +2557,7 @@ def test_query_style_form_explode_true_object_all_of(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2578,14 +2578,14 @@ def test_query_style_form_explode_true_object_all_of_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2624,7 +2624,7 @@ def test_query_style_form_explode_true_object_all_of_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2645,14 +2645,14 @@ def test_query_style_form_explode_true_object_all_of_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2691,7 +2691,7 @@ def test_query_style_form_explode_true_object_all_of_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2712,15 +2712,15 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2745,7 +2745,7 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2770,18 +2770,18 @@ def _test_query_style_form_explode_true_object_all_of_serialize(
def test_query_style_json_serialization_object(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Test query parameter(s)
@@ -2791,7 +2791,7 @@ def test_query_style_json_serialization_object(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2823,7 +2823,7 @@ def test_query_style_json_serialization_object(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2841,18 +2841,18 @@ def test_query_style_json_serialization_object(
def test_query_style_json_serialization_object_with_http_info(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Test query parameter(s)
@@ -2862,7 +2862,7 @@ def test_query_style_json_serialization_object_with_http_info(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2894,7 +2894,7 @@ def test_query_style_json_serialization_object_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2912,18 +2912,18 @@ def test_query_style_json_serialization_object_with_http_info(
def test_query_style_json_serialization_object_without_preload_content(
self,
json_serialized_object_ref_string_query: Optional[Pet] = None,
- json_serialized_object_array_ref_string_query: Optional[List[Pet]] = None,
+ json_serialized_object_array_ref_string_query: Optional[list[Pet]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Test query parameter(s)
@@ -2933,7 +2933,7 @@ def test_query_style_json_serialization_object_without_preload_content(
:param json_serialized_object_ref_string_query:
:type json_serialized_object_ref_string_query: Pet
:param json_serialized_object_array_ref_string_query:
- :type json_serialized_object_array_ref_string_query: List[Pet]
+ :type json_serialized_object_array_ref_string_query: list[Pet]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2965,7 +2965,7 @@ def test_query_style_json_serialization_object_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2987,16 +2987,16 @@ def _test_query_style_json_serialization_object_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'json_serialized_object_array_ref_string_query': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3025,7 +3025,7 @@ def _test_query_style_json_serialization_object_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/client/echo_api/python/openapi_client/api_client.py b/samples/client/echo_api/python/openapi_client/api_client.py
index 4b824e431f11..decd2c6213c4 100644
--- a/samples/client/echo_api/python/openapi_client/api_client.py
+++ b/samples/client/echo_api/python/openapi_client/api_client.py
@@ -24,7 +24,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from openapi_client.configuration import Configuration
@@ -41,7 +41,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -287,7 +287,7 @@ def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -435,16 +435,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -479,7 +479,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -509,7 +509,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -543,7 +543,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -576,7 +576,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/client/echo_api/python/openapi_client/configuration.py b/samples/client/echo_api/python/openapi_client/configuration.py
index ced011ff8def..03fdce72e33a 100644
--- a/samples/client/echo_api/python/openapi_client/configuration.py
+++ b/samples/client/echo_api/python/openapi_client/configuration.py
@@ -17,7 +17,7 @@
from logging import FileHandler
import multiprocessing
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
import urllib3
@@ -29,7 +29,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -122,13 +122,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -202,15 +202,15 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[Union[int, urllib3.util.retry.Retry]] = None,
@@ -355,7 +355,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -561,7 +561,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -577,7 +577,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/client/echo_api/python/openapi_client/models/bird.py b/samples/client/echo_api/python/openapi_client/models/bird.py
index 97c0cf36eb54..522b7fb4a268 100644
--- a/samples/client/echo_api/python/openapi_client/models/bird.py
+++ b/samples/client/echo_api/python/openapi_client/models/bird.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Bird(BaseModel):
""" # noqa: E501
size: Optional[StrictStr] = None
color: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["size", "color"]
+ __properties: ClassVar[list[str]] = ["size", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bird from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bird from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/category.py b/samples/client/echo_api/python/openapi_client/models/category.py
index 627445b692e6..d8abdfc75113 100644
--- a/samples/client/echo_api/python/openapi_client/models/category.py
+++ b/samples/client/echo_api/python/openapi_client/models/category.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/data_query.py b/samples/client/echo_api/python/openapi_client/models/data_query.py
index 0642020815c5..05521fb03a3d 100644
--- a/samples/client/echo_api/python/openapi_client/models/data_query.py
+++ b/samples/client/echo_api/python/openapi_client/models/data_query.py
@@ -20,9 +20,9 @@
from datetime import datetime
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.query import Query
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class DataQuery(Query):
suffix: Optional[StrictStr] = Field(default=None, description="test suffix")
text: Optional[StrictStr] = Field(default=None, description="Some text containing white spaces")
var_date: Optional[datetime] = Field(default=None, description="A date", alias="date")
- __properties: ClassVar[List[str]] = ["id", "outcomes", "suffix", "text", "date"]
+ __properties: ClassVar[list[str]] = ["id", "outcomes", "suffix", "text", "date"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DataQuery from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DataQuery from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/default_value.py b/samples/client/echo_api/python/openapi_client/models/default_value.py
index 70883914b34f..f94adfb17925 100644
--- a/samples/client/echo_api/python/openapi_client/models/default_value.py
+++ b/samples/client/echo_api/python/openapi_client/models/default_value.py
@@ -19,9 +19,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.string_enum_ref import StringEnumRef
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,15 +29,15 @@ class DefaultValue(BaseModel):
"""
to test the default value of properties
""" # noqa: E501
- array_string_enum_ref_default: Optional[List[StringEnumRef]] = None
- array_string_enum_default: Optional[List[StrictStr]] = None
- array_string_default: Optional[List[StrictStr]] = None
- array_integer_default: Optional[List[StrictInt]] = None
- array_string: Optional[List[StrictStr]] = None
- array_string_nullable: Optional[List[StrictStr]] = None
- array_string_extension_nullable: Optional[List[StrictStr]] = None
+ array_string_enum_ref_default: Optional[list[StringEnumRef]] = None
+ array_string_enum_default: Optional[list[StrictStr]] = None
+ array_string_default: Optional[list[StrictStr]] = None
+ array_integer_default: Optional[list[StrictInt]] = None
+ array_string: Optional[list[StrictStr]] = None
+ array_string_nullable: Optional[list[StrictStr]] = None
+ array_string_extension_nullable: Optional[list[StrictStr]] = None
string_nullable: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["array_string_enum_ref_default", "array_string_enum_default", "array_string_default", "array_integer_default", "array_string", "array_string_nullable", "array_string_extension_nullable", "string_nullable"]
+ __properties: ClassVar[list[str]] = ["array_string_enum_ref_default", "array_string_enum_default", "array_string_default", "array_integer_default", "array_string", "array_string_nullable", "array_string_extension_nullable", "string_nullable"]
@field_validator('array_string_enum_default')
def array_string_enum_default_validate_enum(cls, value):
@@ -71,7 +71,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -107,7 +107,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py
index 5f5cd1367f07..0e4d8493c5c5 100644
--- a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py
+++ b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py
@@ -19,9 +19,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class NumberPropertiesOnly(BaseModel):
number: Optional[Union[StrictFloat, StrictInt]] = None
var_float: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="float")
double: Optional[Union[Annotated[float, Field(le=50.2, strict=True, ge=0.8)], Annotated[int, Field(le=50, strict=True, ge=1)]]] = None
- __properties: ClassVar[List[str]] = ["number", "float", "double"]
+ __properties: ClassVar[list[str]] = ["number", "float", "double"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberPropertiesOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberPropertiesOnly from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/pet.py b/samples/client/echo_api/python/openapi_client/models/pet.py
index 4d307019734b..0b1783ecc3da 100644
--- a/samples/client/echo_api/python/openapi_client/models/pet.py
+++ b/samples/client/echo_api/python/openapi_client/models/pet.py
@@ -19,10 +19,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_client.models.category import Category
from openapi_client.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,10 +33,10 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
name: StrictStr
category: Optional[Category] = None
- photo_urls: List[StrictStr] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: list[StrictStr] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- __properties: ClassVar[List[str]] = ["id", "name", "category", "photoUrls", "tags", "status"]
+ __properties: ClassVar[list[str]] = ["id", "name", "category", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -69,7 +69,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/query.py b/samples/client/echo_api/python/openapi_client/models/query.py
index 2114ca55db44..344da3c251b7 100644
--- a/samples/client/echo_api/python/openapi_client/models/query.py
+++ b/samples/client/echo_api/python/openapi_client/models/query.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Query(BaseModel):
Query
""" # noqa: E501
id: Optional[StrictInt] = Field(default=None, description="Query")
- outcomes: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["id", "outcomes"]
+ outcomes: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["id", "outcomes"]
@field_validator('outcomes')
def outcomes_validate_enum(cls, value):
@@ -64,7 +64,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Query from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Self]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Self]:
"""Create an instance of Query from a dict"""
diff --git a/samples/client/echo_api/python/openapi_client/models/tag.py b/samples/client/echo_api/python/openapi_client/models/tag.py
index 36b0196d0db8..6fbc3d6c913a 100644
--- a/samples/client/echo_api/python/openapi_client/models/tag.py
+++ b/samples/client/echo_api/python/openapi_client/models/tag.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py
index 713fc0196d58..5a1f93b79119 100644
--- a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py
+++ b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class TestFormObjectMultipartRequestMarker(BaseModel):
TestFormObjectMultipartRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestFormObjectMultipartRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestFormObjectMultipartRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
index be14155b5611..a8e5ffced881 100644
--- a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
+++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter(BaseMod
color: Optional[StrictStr] = None
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["size", "color", "id", "name"]
+ __properties: ClassVar[list[str]] = ["size", "color", "id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter from a dict"""
if obj is None:
return None
diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
index 5f8b9b5af3e1..bbf23555f8fe 100644
--- a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
+++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
@@ -19,8 +19,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter(BaseModel):
"""
TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
""" # noqa: E501
- values: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["values"]
+ values: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["values"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter from a dict"""
if obj is None:
return None
diff --git a/samples/client/others/c/bearerAuth/api/DefaultAPI.h b/samples/client/others/c/bearerAuth/api/DefaultAPI.h
index dc576a2d49bb..523504ba6459 100644
--- a/samples/client/others/c/bearerAuth/api/DefaultAPI.h
+++ b/samples/client/others/c/bearerAuth/api/DefaultAPI.h
@@ -5,7 +5,6 @@
#include "../external/cJSON.h"
#include "../include/keyValuePair.h"
#include "../include/binary.h"
-#include "../model/object.h"
// Returns private information.
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-aiohttp/docs/AdditionalPropertiesClass.md
index 5128004d8f9a..faa22e6e6b1b 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/AdditionalPropertiesClass.md
@@ -5,9 +5,9 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfModel.md
index f866863d53f9..13c6bc20804d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
index 32bd2dfbf1e2..8fa0d5954ad1 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfMapModel.md
index fd39f86fce5e..44ee01bb37b6 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfMapModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfNumberOnly.md
index b814d7594942..bc690d09040a 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayTest.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayTest.md
index ed871fae662d..014e64472c22 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ArrayTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[Optional[float]]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[Optional[float]]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python-aiohttp/docs/CircularAllOfRef.md
index 65b171177e58..d39dfe136b9f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/CircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/EnumArrays.md b/samples/openapi3/client/petstore/python-aiohttp/docs/EnumArrays.md
index f44617497bce..687172987bc6 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/EnumArrays.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/FakeApi.md b/samples/openapi3/client/petstore/python-aiohttp/docs/FakeApi.md
index 8f79394afc28..a69ca16e828d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/FakeApi.md
@@ -651,7 +651,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = await api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -669,7 +669,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1121,7 +1121,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1163,7 +1163,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1393,7 +1393,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1409,7 +1409,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2093,7 +2093,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2109,7 +2109,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2350,13 +2350,13 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
await api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2371,13 +2371,13 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2426,7 +2426,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2442,7 +2442,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python-aiohttp/docs/FileSchemaTestClass.md
index e1118042a8ec..aae04a5bbba7 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/FileSchemaTestClass.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/InputAllOf.md b/samples/openapi3/client/petstore/python-aiohttp/docs/InputAllOf.md
index 45298f5308fc..adc4f9cdcb63 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/InputAllOf.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python-aiohttp/docs/MapOfArrayOfModel.md
index 71a4ef66b682..d2a7c41b46f9 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/MapOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/MapTest.md b/samples/openapi3/client/petstore/python-aiohttp/docs/MapTest.md
index d04b82e9378c..33032142168b 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/MapTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 84134317aefc..7e5fb0b3071d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **UUID** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/MultiArrays.md b/samples/openapi3/client/petstore/python-aiohttp/docs/MultiArrays.md
index fea5139e7e73..62398cd42693 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/MultiArrays.md
@@ -5,8 +5,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/NullableClass.md b/samples/openapi3/client/petstore/python-aiohttp/docs/NullableClass.md
index 0387dcc2c67a..1378ee707136 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/NullableClass.md
@@ -12,12 +12,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[Optional[object]]** | | [optional]
-**array_items_nullable** | **List[Optional[object]]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, Optional[object]]** | | [optional]
-**object_items_nullable** | **Dict[str, Optional[object]]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[Optional[object]]** | | [optional]
+**array_items_nullable** | **list[Optional[object]]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, Optional[object]]** | | [optional]
+**object_items_nullable** | **dict[str, Optional[object]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ObjectWithDeprecatedFields.md
index 6dbd2ace04f1..fcdff0bdf060 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ObjectWithDeprecatedFields.md
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/Parent.md b/samples/openapi3/client/petstore/python-aiohttp/docs/Parent.md
index 7387f9250aad..56fbac8cbb28 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/Parent.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python-aiohttp/docs/ParentWithOptionalDict.md
index bfc8688ea26f..7d278755c08f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/ParentWithOptionalDict.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/Pet.md b/samples/openapi3/client/petstore/python-aiohttp/docs/Pet.md
index 5329cf2fb925..14d1e224a08a 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/PetApi.md b/samples/openapi3/client/petstore/python-aiohttp/docs/PetApi.md
index 4dda39306a29..478ac90eeb82 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/PetApi.md
@@ -228,7 +228,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -324,7 +324,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -342,11 +342,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -367,7 +367,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -463,7 +463,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -481,11 +481,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/PropertyMap.md b/samples/openapi3/client/petstore/python-aiohttp/docs/PropertyMap.md
index a55a0e5c6f01..0c32115e8200 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/PropertyMap.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python-aiohttp/docs/SecondCircularAllOfRef.md
index 65ebdd4c7e1d..894564db2594 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/SecondCircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/StoreApi.md b/samples/openapi3/client/petstore/python-aiohttp/docs/StoreApi.md
index 27f240911fcb..eb1367bf4d1b 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/StoreApi.md
@@ -77,7 +77,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -131,7 +131,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
index 68cd00ab0a7a..dbf6ee475056 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
index 045b0e22ad09..f9bf8d7b3489 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-aiohttp/docs/UserApi.md b/samples/openapi3/client/petstore/python-aiohttp/docs/UserApi.md
index 5bb4ccfdf228..2ce4b6e4fa2f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python-aiohttp/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -123,7 +123,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -173,7 +173,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -189,7 +189,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/another_fake_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/another_fake_api.py
index 9ceb307bbb24..aff4e8f9ad04 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/another_fake_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/another_fake_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ async def call_123_test_special_tags(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test special tags
@@ -90,7 +90,7 @@ async def call_123_test_special_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -111,14 +111,14 @@ async def call_123_test_special_tags_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test special tags
@@ -157,7 +157,7 @@ async def call_123_test_special_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -178,14 +178,14 @@ async def call_123_test_special_tags_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test special tags
@@ -224,7 +224,7 @@ async def call_123_test_special_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -245,15 +245,15 @@ def _call_123_test_special_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _call_123_test_special_tags_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/default_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/default_api.py
index 13aec70c14ed..ae9cdb4faaf6 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/default_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/default_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from petstore_api.models.foo_get_default_response import FooGetDefaultResponse
@@ -41,14 +41,14 @@ async def foo_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> FooGetDefaultResponse:
"""foo_get
@@ -83,7 +83,7 @@ async def foo_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -102,14 +102,14 @@ async def foo_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[FooGetDefaultResponse]:
"""foo_get
@@ -144,7 +144,7 @@ async def foo_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -163,14 +163,14 @@ async def foo_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""foo_get
@@ -205,7 +205,7 @@ async def foo_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -224,15 +224,15 @@ def _foo_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -253,7 +253,7 @@ def _foo_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_api.py
index 9e895f7806ee..2380caae8a1a 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_api.py
@@ -12,12 +12,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
from petstore_api.models.client import Client
@@ -56,18 +56,18 @@ def __init__(self, api_client=None) -> None:
@validate_call
async def fake_any_type_request_body(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test any type request body
@@ -105,7 +105,7 @@ async def fake_any_type_request_body(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -122,18 +122,18 @@ async def fake_any_type_request_body(
@validate_call
async def fake_any_type_request_body_with_http_info(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test any type request body
@@ -171,7 +171,7 @@ async def fake_any_type_request_body_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -188,18 +188,18 @@ async def fake_any_type_request_body_with_http_info(
@validate_call
async def fake_any_type_request_body_without_preload_content(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test any type request body
@@ -237,7 +237,7 @@ async def fake_any_type_request_body_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -258,15 +258,15 @@ def _fake_any_type_request_body_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -295,7 +295,7 @@ def _fake_any_type_request_body_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -323,14 +323,14 @@ async def fake_enum_ref_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test enum reference query parameter
@@ -368,7 +368,7 @@ async def fake_enum_ref_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -389,14 +389,14 @@ async def fake_enum_ref_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test enum reference query parameter
@@ -434,7 +434,7 @@ async def fake_enum_ref_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -455,14 +455,14 @@ async def fake_enum_ref_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum reference query parameter
@@ -500,7 +500,7 @@ async def fake_enum_ref_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -521,15 +521,15 @@ def _fake_enum_ref_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -547,7 +547,7 @@ def _fake_enum_ref_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,14 +574,14 @@ async def fake_health_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> HealthCheckResult:
"""Health check endpoint
@@ -616,7 +616,7 @@ async def fake_health_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -636,14 +636,14 @@ async def fake_health_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[HealthCheckResult]:
"""Health check endpoint
@@ -678,7 +678,7 @@ async def fake_health_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -698,14 +698,14 @@ async def fake_health_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Health check endpoint
@@ -740,7 +740,7 @@ async def fake_health_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -760,15 +760,15 @@ def _fake_health_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -789,7 +789,7 @@ def _fake_health_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -819,14 +819,14 @@ async def fake_http_signature_test(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test http signature authentication
@@ -870,7 +870,7 @@ async def fake_http_signature_test(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -893,14 +893,14 @@ async def fake_http_signature_test_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test http signature authentication
@@ -944,7 +944,7 @@ async def fake_http_signature_test_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -967,14 +967,14 @@ async def fake_http_signature_test_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test http signature authentication
@@ -1018,7 +1018,7 @@ async def fake_http_signature_test_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -1041,15 +1041,15 @@ def _fake_http_signature_test_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1085,7 +1085,7 @@ def _fake_http_signature_test_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_signature_test'
]
@@ -1114,14 +1114,14 @@ async def fake_outer_boolean_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""fake_outer_boolean_serialize
@@ -1160,7 +1160,7 @@ async def fake_outer_boolean_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1181,14 +1181,14 @@ async def fake_outer_boolean_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""fake_outer_boolean_serialize
@@ -1227,7 +1227,7 @@ async def fake_outer_boolean_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1248,14 +1248,14 @@ async def fake_outer_boolean_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_boolean_serialize
@@ -1294,7 +1294,7 @@ async def fake_outer_boolean_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1315,15 +1315,15 @@ def _fake_outer_boolean_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1359,7 +1359,7 @@ def _fake_outer_boolean_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1387,14 +1387,14 @@ async def fake_outer_composite_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterComposite:
"""fake_outer_composite_serialize
@@ -1433,7 +1433,7 @@ async def fake_outer_composite_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1454,14 +1454,14 @@ async def fake_outer_composite_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterComposite]:
"""fake_outer_composite_serialize
@@ -1500,7 +1500,7 @@ async def fake_outer_composite_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1521,14 +1521,14 @@ async def fake_outer_composite_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_composite_serialize
@@ -1567,7 +1567,7 @@ async def fake_outer_composite_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1588,15 +1588,15 @@ def _fake_outer_composite_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1632,7 +1632,7 @@ def _fake_outer_composite_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1660,14 +1660,14 @@ async def fake_outer_number_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""fake_outer_number_serialize
@@ -1706,7 +1706,7 @@ async def fake_outer_number_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1727,14 +1727,14 @@ async def fake_outer_number_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""fake_outer_number_serialize
@@ -1773,7 +1773,7 @@ async def fake_outer_number_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1794,14 +1794,14 @@ async def fake_outer_number_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_number_serialize
@@ -1840,7 +1840,7 @@ async def fake_outer_number_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1861,15 +1861,15 @@ def _fake_outer_number_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1905,7 +1905,7 @@ def _fake_outer_number_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1933,14 +1933,14 @@ async def fake_outer_string_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""fake_outer_string_serialize
@@ -1979,7 +1979,7 @@ async def fake_outer_string_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2000,14 +2000,14 @@ async def fake_outer_string_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""fake_outer_string_serialize
@@ -2046,7 +2046,7 @@ async def fake_outer_string_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2067,14 +2067,14 @@ async def fake_outer_string_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_string_serialize
@@ -2113,7 +2113,7 @@ async def fake_outer_string_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2134,15 +2134,15 @@ def _fake_outer_string_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2178,7 +2178,7 @@ def _fake_outer_string_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2203,18 +2203,18 @@ def _fake_outer_string_serialize_serialize(
async def fake_property_enum_integer_serialize(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterObjectWithEnumProperty:
"""fake_property_enum_integer_serialize
@@ -2224,7 +2224,7 @@ async def fake_property_enum_integer_serialize(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2256,7 +2256,7 @@ async def fake_property_enum_integer_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2274,18 +2274,18 @@ async def fake_property_enum_integer_serialize(
async def fake_property_enum_integer_serialize_with_http_info(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterObjectWithEnumProperty]:
"""fake_property_enum_integer_serialize
@@ -2295,7 +2295,7 @@ async def fake_property_enum_integer_serialize_with_http_info(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2327,7 +2327,7 @@ async def fake_property_enum_integer_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2345,18 +2345,18 @@ async def fake_property_enum_integer_serialize_with_http_info(
async def fake_property_enum_integer_serialize_without_preload_content(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_property_enum_integer_serialize
@@ -2366,7 +2366,7 @@ async def fake_property_enum_integer_serialize_without_preload_content(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2398,7 +2398,7 @@ async def fake_property_enum_integer_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2420,16 +2420,16 @@ def _fake_property_enum_integer_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'param': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2469,7 +2469,7 @@ def _fake_property_enum_integer_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2496,14 +2496,14 @@ async def fake_ref_enum_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> EnumClass:
"""test ref to enum string
@@ -2538,7 +2538,7 @@ async def fake_ref_enum_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2558,14 +2558,14 @@ async def fake_ref_enum_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[EnumClass]:
"""test ref to enum string
@@ -2600,7 +2600,7 @@ async def fake_ref_enum_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2620,14 +2620,14 @@ async def fake_ref_enum_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test ref to enum string
@@ -2662,7 +2662,7 @@ async def fake_ref_enum_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2682,15 +2682,15 @@ def _fake_ref_enum_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2711,7 +2711,7 @@ def _fake_ref_enum_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2738,14 +2738,14 @@ async def fake_return_boolean(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""test returning boolean
@@ -2780,7 +2780,7 @@ async def fake_return_boolean(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2800,14 +2800,14 @@ async def fake_return_boolean_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""test returning boolean
@@ -2842,7 +2842,7 @@ async def fake_return_boolean_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2862,14 +2862,14 @@ async def fake_return_boolean_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning boolean
@@ -2904,7 +2904,7 @@ async def fake_return_boolean_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2924,15 +2924,15 @@ def _fake_return_boolean_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2953,7 +2953,7 @@ def _fake_return_boolean_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2980,14 +2980,14 @@ async def fake_return_byte_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""test byte like json
@@ -3022,7 +3022,7 @@ async def fake_return_byte_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3042,14 +3042,14 @@ async def fake_return_byte_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""test byte like json
@@ -3084,7 +3084,7 @@ async def fake_return_byte_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3104,14 +3104,14 @@ async def fake_return_byte_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test byte like json
@@ -3146,7 +3146,7 @@ async def fake_return_byte_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3166,15 +3166,15 @@ def _fake_return_byte_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3195,7 +3195,7 @@ def _fake_return_byte_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3222,14 +3222,14 @@ async def fake_return_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning enum
@@ -3264,7 +3264,7 @@ async def fake_return_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3284,14 +3284,14 @@ async def fake_return_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning enum
@@ -3326,7 +3326,7 @@ async def fake_return_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3346,14 +3346,14 @@ async def fake_return_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning enum
@@ -3388,7 +3388,7 @@ async def fake_return_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3408,15 +3408,15 @@ def _fake_return_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3437,7 +3437,7 @@ def _fake_return_enum_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3464,14 +3464,14 @@ async def fake_return_enum_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test enum like json
@@ -3506,7 +3506,7 @@ async def fake_return_enum_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3526,14 +3526,14 @@ async def fake_return_enum_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test enum like json
@@ -3568,7 +3568,7 @@ async def fake_return_enum_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3588,14 +3588,14 @@ async def fake_return_enum_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum like json
@@ -3630,7 +3630,7 @@ async def fake_return_enum_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3650,15 +3650,15 @@ def _fake_return_enum_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3679,7 +3679,7 @@ def _fake_return_enum_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3706,14 +3706,14 @@ async def fake_return_float(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""test returning float
@@ -3748,7 +3748,7 @@ async def fake_return_float(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3768,14 +3768,14 @@ async def fake_return_float_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""test returning float
@@ -3810,7 +3810,7 @@ async def fake_return_float_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3830,14 +3830,14 @@ async def fake_return_float_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning float
@@ -3872,7 +3872,7 @@ async def fake_return_float_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3892,15 +3892,15 @@ def _fake_return_float_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3921,7 +3921,7 @@ def _fake_return_float_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3948,14 +3948,14 @@ async def fake_return_int(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> int:
"""test returning int
@@ -3990,7 +3990,7 @@ async def fake_return_int(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4010,14 +4010,14 @@ async def fake_return_int_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[int]:
"""test returning int
@@ -4052,7 +4052,7 @@ async def fake_return_int_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4072,14 +4072,14 @@ async def fake_return_int_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning int
@@ -4114,7 +4114,7 @@ async def fake_return_int_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4134,15 +4134,15 @@ def _fake_return_int_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4163,7 +4163,7 @@ def _fake_return_int_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4190,16 +4190,16 @@ async def fake_return_list_of_objects(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[List[Tag]]:
+ ) -> list[list[Tag]]:
"""test returning list of objects
@@ -4232,8 +4232,8 @@ async def fake_return_list_of_objects(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4252,16 +4252,16 @@ async def fake_return_list_of_objects_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[List[Tag]]]:
+ ) -> ApiResponse[list[list[Tag]]]:
"""test returning list of objects
@@ -4294,8 +4294,8 @@ async def fake_return_list_of_objects_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4314,14 +4314,14 @@ async def fake_return_list_of_objects_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning list of objects
@@ -4356,8 +4356,8 @@ async def fake_return_list_of_objects_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4376,15 +4376,15 @@ def _fake_return_list_of_objects_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4405,7 +4405,7 @@ def _fake_return_list_of_objects_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4432,14 +4432,14 @@ async def fake_return_str_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test str like json
@@ -4474,7 +4474,7 @@ async def fake_return_str_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4494,14 +4494,14 @@ async def fake_return_str_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test str like json
@@ -4536,7 +4536,7 @@ async def fake_return_str_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4556,14 +4556,14 @@ async def fake_return_str_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test str like json
@@ -4598,7 +4598,7 @@ async def fake_return_str_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4618,15 +4618,15 @@ def _fake_return_str_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4647,7 +4647,7 @@ def _fake_return_str_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4674,14 +4674,14 @@ async def fake_return_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning string
@@ -4716,7 +4716,7 @@ async def fake_return_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4736,14 +4736,14 @@ async def fake_return_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning string
@@ -4778,7 +4778,7 @@ async def fake_return_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4798,14 +4798,14 @@ async def fake_return_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning string
@@ -4840,7 +4840,7 @@ async def fake_return_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4860,15 +4860,15 @@ def _fake_return_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4889,7 +4889,7 @@ def _fake_return_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4917,14 +4917,14 @@ async def fake_uuid_example(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test uuid example
@@ -4962,7 +4962,7 @@ async def fake_uuid_example(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -4983,14 +4983,14 @@ async def fake_uuid_example_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test uuid example
@@ -5028,7 +5028,7 @@ async def fake_uuid_example_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5049,14 +5049,14 @@ async def fake_uuid_example_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test uuid example
@@ -5094,7 +5094,7 @@ async def fake_uuid_example_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5115,15 +5115,15 @@ def _fake_uuid_example_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5141,7 +5141,7 @@ def _fake_uuid_example_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5165,18 +5165,18 @@ def _fake_uuid_example_serialize(
@validate_call
async def test_additional_properties_reference(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced additionalProperties
@@ -5184,7 +5184,7 @@ async def test_additional_properties_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5215,7 +5215,7 @@ async def test_additional_properties_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5232,18 +5232,18 @@ async def test_additional_properties_reference(
@validate_call
async def test_additional_properties_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced additionalProperties
@@ -5251,7 +5251,7 @@ async def test_additional_properties_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5282,7 +5282,7 @@ async def test_additional_properties_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5299,18 +5299,18 @@ async def test_additional_properties_reference_with_http_info(
@validate_call
async def test_additional_properties_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced additionalProperties
@@ -5318,7 +5318,7 @@ async def test_additional_properties_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5349,7 +5349,7 @@ async def test_additional_properties_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5370,15 +5370,15 @@ def _test_additional_properties_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5407,7 +5407,7 @@ def _test_additional_properties_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5431,18 +5431,18 @@ def _test_additional_properties_reference_serialize(
@validate_call
async def test_body_with_binary(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_binary
@@ -5481,7 +5481,7 @@ async def test_body_with_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5498,18 +5498,18 @@ async def test_body_with_binary(
@validate_call
async def test_body_with_binary_with_http_info(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_binary
@@ -5548,7 +5548,7 @@ async def test_body_with_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5565,18 +5565,18 @@ async def test_body_with_binary_with_http_info(
@validate_call
async def test_body_with_binary_without_preload_content(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_binary
@@ -5615,7 +5615,7 @@ async def test_body_with_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5636,15 +5636,15 @@ def _test_body_with_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5681,7 +5681,7 @@ def _test_body_with_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5709,14 +5709,14 @@ async def test_body_with_file_schema(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_file_schema
@@ -5755,7 +5755,7 @@ async def test_body_with_file_schema(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5776,14 +5776,14 @@ async def test_body_with_file_schema_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_file_schema
@@ -5822,7 +5822,7 @@ async def test_body_with_file_schema_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5843,14 +5843,14 @@ async def test_body_with_file_schema_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_file_schema
@@ -5889,7 +5889,7 @@ async def test_body_with_file_schema_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5910,15 +5910,15 @@ def _test_body_with_file_schema_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5947,7 +5947,7 @@ def _test_body_with_file_schema_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5976,14 +5976,14 @@ async def test_body_with_query_params(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_query_params
@@ -6024,7 +6024,7 @@ async def test_body_with_query_params(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6046,14 +6046,14 @@ async def test_body_with_query_params_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_query_params
@@ -6094,7 +6094,7 @@ async def test_body_with_query_params_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6116,14 +6116,14 @@ async def test_body_with_query_params_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_query_params
@@ -6164,7 +6164,7 @@ async def test_body_with_query_params_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6186,15 +6186,15 @@ def _test_body_with_query_params_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6227,7 +6227,7 @@ def _test_body_with_query_params_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6255,14 +6255,14 @@ async def test_client_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test \"client\" model
@@ -6301,7 +6301,7 @@ async def test_client_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6322,14 +6322,14 @@ async def test_client_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test \"client\" model
@@ -6368,7 +6368,7 @@ async def test_client_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6389,14 +6389,14 @@ async def test_client_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test \"client\" model
@@ -6435,7 +6435,7 @@ async def test_client_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6456,15 +6456,15 @@ def _test_client_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6500,7 +6500,7 @@ def _test_client_model_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6529,14 +6529,14 @@ async def test_date_time_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_date_time_query_parameter
@@ -6577,7 +6577,7 @@ async def test_date_time_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6599,14 +6599,14 @@ async def test_date_time_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_date_time_query_parameter
@@ -6647,7 +6647,7 @@ async def test_date_time_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6669,14 +6669,14 @@ async def test_date_time_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_date_time_query_parameter
@@ -6717,7 +6717,7 @@ async def test_date_time_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6739,15 +6739,15 @@ def _test_date_time_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6778,7 +6778,7 @@ def _test_date_time_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6805,14 +6805,14 @@ async def test_empty_and_non_empty_responses(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test empty and non-empty responses
@@ -6848,7 +6848,7 @@ async def test_empty_and_non_empty_responses(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6869,14 +6869,14 @@ async def test_empty_and_non_empty_responses_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test empty and non-empty responses
@@ -6912,7 +6912,7 @@ async def test_empty_and_non_empty_responses_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6933,14 +6933,14 @@ async def test_empty_and_non_empty_responses_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test empty and non-empty responses
@@ -6976,7 +6976,7 @@ async def test_empty_and_non_empty_responses_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6997,15 +6997,15 @@ def _test_empty_and_non_empty_responses_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7026,7 +7026,7 @@ def _test_empty_and_non_empty_responses_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7059,7 +7059,7 @@ async def test_endpoint_parameters(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7068,14 +7068,14 @@ async def test_endpoint_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7156,7 +7156,7 @@ async def test_endpoint_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7183,7 +7183,7 @@ async def test_endpoint_parameters_with_http_info(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7192,14 +7192,14 @@ async def test_endpoint_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7280,7 +7280,7 @@ async def test_endpoint_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7307,7 +7307,7 @@ async def test_endpoint_parameters_without_preload_content(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7316,14 +7316,14 @@ async def test_endpoint_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7404,7 +7404,7 @@ async def test_endpoint_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7440,15 +7440,15 @@ def _test_endpoint_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7505,7 +7505,7 @@ def _test_endpoint_parameters_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_basic_test'
]
@@ -7533,14 +7533,14 @@ async def test_error_responses_with_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test error responses with model
@@ -7575,7 +7575,7 @@ async def test_error_responses_with_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7597,14 +7597,14 @@ async def test_error_responses_with_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test error responses with model
@@ -7639,7 +7639,7 @@ async def test_error_responses_with_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7661,14 +7661,14 @@ async def test_error_responses_with_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test error responses with model
@@ -7703,7 +7703,7 @@ async def test_error_responses_with_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7725,15 +7725,15 @@ def _test_error_responses_with_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7754,7 +7754,7 @@ def _test_error_responses_with_model_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7787,14 +7787,14 @@ async def test_group_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint to test group parameters (optional)
@@ -7848,7 +7848,7 @@ async def test_group_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -7874,14 +7874,14 @@ async def test_group_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint to test group parameters (optional)
@@ -7935,7 +7935,7 @@ async def test_group_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -7961,14 +7961,14 @@ async def test_group_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint to test group parameters (optional)
@@ -8022,7 +8022,7 @@ async def test_group_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -8048,15 +8048,15 @@ def _test_group_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8090,7 +8090,7 @@ def _test_group_parameters_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'bearer_test'
]
@@ -8115,18 +8115,18 @@ def _test_group_parameters_serialize(
@validate_call
async def test_inline_additional_properties(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline additionalProperties
@@ -8134,7 +8134,7 @@ async def test_inline_additional_properties(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8165,7 +8165,7 @@ async def test_inline_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8182,18 +8182,18 @@ async def test_inline_additional_properties(
@validate_call
async def test_inline_additional_properties_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline additionalProperties
@@ -8201,7 +8201,7 @@ async def test_inline_additional_properties_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8232,7 +8232,7 @@ async def test_inline_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8249,18 +8249,18 @@ async def test_inline_additional_properties_with_http_info(
@validate_call
async def test_inline_additional_properties_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline additionalProperties
@@ -8268,7 +8268,7 @@ async def test_inline_additional_properties_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8299,7 +8299,7 @@ async def test_inline_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8320,15 +8320,15 @@ def _test_inline_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8357,7 +8357,7 @@ def _test_inline_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8385,14 +8385,14 @@ async def test_inline_freeform_additional_properties(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline free-form additionalProperties
@@ -8431,7 +8431,7 @@ async def test_inline_freeform_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8452,14 +8452,14 @@ async def test_inline_freeform_additional_properties_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline free-form additionalProperties
@@ -8498,7 +8498,7 @@ async def test_inline_freeform_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8519,14 +8519,14 @@ async def test_inline_freeform_additional_properties_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline free-form additionalProperties
@@ -8565,7 +8565,7 @@ async def test_inline_freeform_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8586,15 +8586,15 @@ def _test_inline_freeform_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8623,7 +8623,7 @@ def _test_inline_freeform_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8652,14 +8652,14 @@ async def test_json_form_data(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test json serialization of form data
@@ -8701,7 +8701,7 @@ async def test_json_form_data(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8723,14 +8723,14 @@ async def test_json_form_data_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test json serialization of form data
@@ -8772,7 +8772,7 @@ async def test_json_form_data_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8794,14 +8794,14 @@ async def test_json_form_data_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test json serialization of form data
@@ -8843,7 +8843,7 @@ async def test_json_form_data_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8865,15 +8865,15 @@ def _test_json_form_data_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8904,7 +8904,7 @@ def _test_json_form_data_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8932,14 +8932,14 @@ async def test_object_for_multipart_requests(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_object_for_multipart_requests
@@ -8977,7 +8977,7 @@ async def test_object_for_multipart_requests(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8998,14 +8998,14 @@ async def test_object_for_multipart_requests_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_object_for_multipart_requests
@@ -9043,7 +9043,7 @@ async def test_object_for_multipart_requests_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9064,14 +9064,14 @@ async def test_object_for_multipart_requests_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_object_for_multipart_requests
@@ -9109,7 +9109,7 @@ async def test_object_for_multipart_requests_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9130,15 +9130,15 @@ def _test_object_for_multipart_requests_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9167,7 +9167,7 @@ def _test_object_for_multipart_requests_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9191,24 +9191,24 @@ def _test_object_for_multipart_requests_serialize(
@validate_call
async def test_query_parameter_collection_format(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_query_parameter_collection_format
@@ -9216,19 +9216,19 @@ async def test_query_parameter_collection_format(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9265,7 +9265,7 @@ async def test_query_parameter_collection_format(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9282,24 +9282,24 @@ async def test_query_parameter_collection_format(
@validate_call
async def test_query_parameter_collection_format_with_http_info(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_query_parameter_collection_format
@@ -9307,19 +9307,19 @@ async def test_query_parameter_collection_format_with_http_info(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9356,7 +9356,7 @@ async def test_query_parameter_collection_format_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9373,24 +9373,24 @@ async def test_query_parameter_collection_format_with_http_info(
@validate_call
async def test_query_parameter_collection_format_without_preload_content(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_query_parameter_collection_format
@@ -9398,19 +9398,19 @@ async def test_query_parameter_collection_format_without_preload_content(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9447,7 +9447,7 @@ async def test_query_parameter_collection_format_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9474,7 +9474,7 @@ def _test_query_parameter_collection_format_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'pipe': 'pipes',
'ioutil': 'csv',
'http': 'ssv',
@@ -9482,12 +9482,12 @@ def _test_query_parameter_collection_format_serialize(
'context': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9529,7 +9529,7 @@ def _test_query_parameter_collection_format_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9553,18 +9553,18 @@ def _test_query_parameter_collection_format_serialize(
@validate_call
async def test_string_map_reference(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced string map
@@ -9572,7 +9572,7 @@ async def test_string_map_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9603,7 +9603,7 @@ async def test_string_map_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9620,18 +9620,18 @@ async def test_string_map_reference(
@validate_call
async def test_string_map_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced string map
@@ -9639,7 +9639,7 @@ async def test_string_map_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9670,7 +9670,7 @@ async def test_string_map_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9687,18 +9687,18 @@ async def test_string_map_reference_with_http_info(
@validate_call
async def test_string_map_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced string map
@@ -9706,7 +9706,7 @@ async def test_string_map_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9737,7 +9737,7 @@ async def test_string_map_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9758,15 +9758,15 @@ def _test_string_map_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9795,7 +9795,7 @@ def _test_string_map_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9819,20 +9819,20 @@ def _test_string_map_reference_serialize(
@validate_call
async def upload_file_with_additional_properties(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads a file and additional properties using multipart/form-data
@@ -9877,7 +9877,7 @@ async def upload_file_with_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -9894,20 +9894,20 @@ async def upload_file_with_additional_properties(
@validate_call
async def upload_file_with_additional_properties_with_http_info(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads a file and additional properties using multipart/form-data
@@ -9952,7 +9952,7 @@ async def upload_file_with_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -9969,20 +9969,20 @@ async def upload_file_with_additional_properties_with_http_info(
@validate_call
async def upload_file_with_additional_properties_without_preload_content(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads a file and additional properties using multipart/form-data
@@ -10027,7 +10027,7 @@ async def upload_file_with_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -10050,15 +10050,15 @@ def _upload_file_with_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -10098,7 +10098,7 @@ def _upload_file_with_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_classname_tags123_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_classname_tags123_api.py
index 08cf85d488bb..e812b272776e 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_classname_tags123_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/fake_classname_tags123_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ async def test_classname(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test class name in snake case
@@ -90,7 +90,7 @@ async def test_classname(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -111,14 +111,14 @@ async def test_classname_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test class name in snake case
@@ -157,7 +157,7 @@ async def test_classname_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -178,14 +178,14 @@ async def test_classname_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test class name in snake case
@@ -224,7 +224,7 @@ async def test_classname_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -245,15 +245,15 @@ def _test_classname_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _test_classname_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key_query'
]
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/import_test_datetime_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/import_test_datetime_api.py
index 47876e858687..5f6dda97e29f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/import_test_datetime_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/import_test_datetime_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import datetime
@@ -41,14 +41,14 @@ async def import_test_return_datetime(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> datetime:
"""test date time
@@ -83,7 +83,7 @@ async def import_test_return_datetime(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -103,14 +103,14 @@ async def import_test_return_datetime_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[datetime]:
"""test date time
@@ -145,7 +145,7 @@ async def import_test_return_datetime_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -165,14 +165,14 @@ async def import_test_return_datetime_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test date time
@@ -207,7 +207,7 @@ async def import_test_return_datetime_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -227,15 +227,15 @@ def _import_test_return_datetime_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -256,7 +256,7 @@ def _import_test_return_datetime_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/pet_api.py
index 5da83f4a686a..3bd9d5df7515 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/pet_api.py
@@ -12,11 +12,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import List, Optional, Tuple, Union
+from typing import Optional, Union
from typing_extensions import Annotated
from petstore_api.models.model_api_response import ModelApiResponse
from petstore_api.models.pet import Pet
@@ -46,14 +46,14 @@ async def add_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Add a new pet to the store
@@ -92,7 +92,7 @@ async def add_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -114,14 +114,14 @@ async def add_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Add a new pet to the store
@@ -160,7 +160,7 @@ async def add_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -182,14 +182,14 @@ async def add_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Add a new pet to the store
@@ -228,7 +228,7 @@ async def add_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -250,15 +250,15 @@ def _add_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -288,7 +288,7 @@ def _add_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -319,14 +319,14 @@ async def delete_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Deletes a pet
@@ -368,7 +368,7 @@ async def delete_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -391,14 +391,14 @@ async def delete_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Deletes a pet
@@ -440,7 +440,7 @@ async def delete_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -463,14 +463,14 @@ async def delete_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Deletes a pet
@@ -512,7 +512,7 @@ async def delete_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -535,15 +535,15 @@ def _delete_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -561,7 +561,7 @@ def _delete_pet_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -586,26 +586,26 @@ def _delete_pet_serialize(
@validate_call
async def find_pets_by_status(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -636,8 +636,8 @@ async def find_pets_by_status(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -654,26 +654,26 @@ async def find_pets_by_status(
@validate_call
async def find_pets_by_status_with_http_info(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -704,8 +704,8 @@ async def find_pets_by_status_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -722,18 +722,18 @@ async def find_pets_by_status_with_http_info(
@validate_call
async def find_pets_by_status_without_preload_content(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Finds Pets by status
@@ -741,7 +741,7 @@ async def find_pets_by_status_without_preload_content(
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -772,8 +772,8 @@ async def find_pets_by_status_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -794,16 +794,16 @@ def _find_pets_by_status_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'status': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -829,7 +829,7 @@ def _find_pets_by_status_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -855,26 +855,26 @@ def _find_pets_by_status_serialize(
@validate_call
async def find_pets_by_tags(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -906,8 +906,8 @@ async def find_pets_by_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -924,26 +924,26 @@ async def find_pets_by_tags(
@validate_call
async def find_pets_by_tags_with_http_info(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -975,8 +975,8 @@ async def find_pets_by_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -993,18 +993,18 @@ async def find_pets_by_tags_with_http_info(
@validate_call
async def find_pets_by_tags_without_preload_content(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""(Deprecated) Finds Pets by tags
@@ -1012,7 +1012,7 @@ async def find_pets_by_tags_without_preload_content(
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1044,8 +1044,8 @@ async def find_pets_by_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -1066,16 +1066,16 @@ def _find_pets_by_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'tags': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1101,7 +1101,7 @@ def _find_pets_by_tags_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1131,14 +1131,14 @@ async def get_pet_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Find pet by ID
@@ -1177,7 +1177,7 @@ async def get_pet_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1200,14 +1200,14 @@ async def get_pet_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Find pet by ID
@@ -1246,7 +1246,7 @@ async def get_pet_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1269,14 +1269,14 @@ async def get_pet_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find pet by ID
@@ -1315,7 +1315,7 @@ async def get_pet_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1338,15 +1338,15 @@ def _get_pet_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1370,7 +1370,7 @@ def _get_pet_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -1399,14 +1399,14 @@ async def update_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Update an existing pet
@@ -1445,7 +1445,7 @@ async def update_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1469,14 +1469,14 @@ async def update_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Update an existing pet
@@ -1515,7 +1515,7 @@ async def update_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1539,14 +1539,14 @@ async def update_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Update an existing pet
@@ -1585,7 +1585,7 @@ async def update_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1609,15 +1609,15 @@ def _update_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1647,7 +1647,7 @@ def _update_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1679,14 +1679,14 @@ async def update_pet_with_form(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updates a pet in the store with form data
@@ -1731,7 +1731,7 @@ async def update_pet_with_form(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1755,14 +1755,14 @@ async def update_pet_with_form_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updates a pet in the store with form data
@@ -1807,7 +1807,7 @@ async def update_pet_with_form_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1831,14 +1831,14 @@ async def update_pet_with_form_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updates a pet in the store with form data
@@ -1883,7 +1883,7 @@ async def update_pet_with_form_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1907,15 +1907,15 @@ def _update_pet_with_form_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1948,7 +1948,7 @@ def _update_pet_with_form_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -1975,18 +1975,18 @@ async def upload_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image
@@ -2031,7 +2031,7 @@ async def upload_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2050,18 +2050,18 @@ async def upload_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image
@@ -2106,7 +2106,7 @@ async def upload_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2125,18 +2125,18 @@ async def upload_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image
@@ -2181,7 +2181,7 @@ async def upload_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2204,15 +2204,15 @@ def _upload_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2252,7 +2252,7 @@ def _upload_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -2278,19 +2278,19 @@ def _upload_file_serialize(
async def upload_file_with_required_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image (required)
@@ -2335,7 +2335,7 @@ async def upload_file_with_required_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2353,19 +2353,19 @@ async def upload_file_with_required_file(
async def upload_file_with_required_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image (required)
@@ -2410,7 +2410,7 @@ async def upload_file_with_required_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2428,19 +2428,19 @@ async def upload_file_with_required_file_with_http_info(
async def upload_file_with_required_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image (required)
@@ -2485,7 +2485,7 @@ async def upload_file_with_required_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2508,15 +2508,15 @@ def _upload_file_with_required_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2556,7 +2556,7 @@ def _upload_file_with_required_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/store_api.py
index 79116ca74ca8..ec95444f06cb 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/store_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictInt, StrictStr
-from typing import Dict
from typing_extensions import Annotated
from petstore_api.models.order import Order
@@ -45,14 +44,14 @@ async def delete_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete purchase order by ID
@@ -91,7 +90,7 @@ async def delete_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -113,14 +112,14 @@ async def delete_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete purchase order by ID
@@ -159,7 +158,7 @@ async def delete_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -181,14 +180,14 @@ async def delete_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete purchase order by ID
@@ -227,7 +226,7 @@ async def delete_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -249,15 +248,15 @@ def _delete_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -273,7 +272,7 @@ def _delete_order_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -300,16 +299,16 @@ async def get_inventory(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> Dict[str, int]:
+ ) -> dict[str, int]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -343,8 +342,8 @@ async def get_inventory(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -363,16 +362,16 @@ async def get_inventory_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[Dict[str, int]]:
+ ) -> ApiResponse[dict[str, int]]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -406,8 +405,8 @@ async def get_inventory_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -426,14 +425,14 @@ async def get_inventory_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Returns pet inventories by status
@@ -469,8 +468,8 @@ async def get_inventory_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -489,15 +488,15 @@ def _get_inventory_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -518,7 +517,7 @@ def _get_inventory_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -547,14 +546,14 @@ async def get_order_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Find purchase order by ID
@@ -593,7 +592,7 @@ async def get_order_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -616,14 +615,14 @@ async def get_order_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Find purchase order by ID
@@ -662,7 +661,7 @@ async def get_order_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -685,14 +684,14 @@ async def get_order_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find purchase order by ID
@@ -731,7 +730,7 @@ async def get_order_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -754,15 +753,15 @@ def _get_order_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -786,7 +785,7 @@ def _get_order_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -814,14 +813,14 @@ async def place_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Place an order for a pet
@@ -860,7 +859,7 @@ async def place_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -882,14 +881,14 @@ async def place_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Place an order for a pet
@@ -928,7 +927,7 @@ async def place_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -950,14 +949,14 @@ async def place_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Place an order for a pet
@@ -996,7 +995,7 @@ async def place_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -1018,15 +1017,15 @@ def _place_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1063,7 +1062,7 @@ def _place_order_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/user_api.py
index 9e4ff6771db8..4d7677c1b7c9 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api/user_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictStr
-from typing import List
from typing_extensions import Annotated
from petstore_api.models.user import User
@@ -45,14 +44,14 @@ async def create_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> None:
"""Create user
@@ -91,7 +90,7 @@ async def create_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -111,14 +110,14 @@ async def create_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> ApiResponse[None]:
"""Create user
@@ -157,7 +156,7 @@ async def create_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -177,14 +176,14 @@ async def create_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> RESTResponseType:
"""Create user
@@ -223,7 +222,7 @@ async def create_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -249,15 +248,15 @@ def _create_user_serialize(
]
_host = _hosts[_host_index]
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -286,7 +285,7 @@ def _create_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -310,18 +309,18 @@ def _create_user_serialize(
@validate_call
async def create_users_with_array_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -329,7 +328,7 @@ async def create_users_with_array_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -360,7 +359,7 @@ async def create_users_with_array_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -376,18 +375,18 @@ async def create_users_with_array_input(
@validate_call
async def create_users_with_array_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -395,7 +394,7 @@ async def create_users_with_array_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -426,7 +425,7 @@ async def create_users_with_array_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -442,18 +441,18 @@ async def create_users_with_array_input_with_http_info(
@validate_call
async def create_users_with_array_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -461,7 +460,7 @@ async def create_users_with_array_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -492,7 +491,7 @@ async def create_users_with_array_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -512,16 +511,16 @@ def _create_users_with_array_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -550,7 +549,7 @@ def _create_users_with_array_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,18 +573,18 @@ def _create_users_with_array_input_serialize(
@validate_call
async def create_users_with_list_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -593,7 +592,7 @@ async def create_users_with_list_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -624,7 +623,7 @@ async def create_users_with_list_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -640,18 +639,18 @@ async def create_users_with_list_input(
@validate_call
async def create_users_with_list_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -659,7 +658,7 @@ async def create_users_with_list_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -690,7 +689,7 @@ async def create_users_with_list_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -706,18 +705,18 @@ async def create_users_with_list_input_with_http_info(
@validate_call
async def create_users_with_list_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -725,7 +724,7 @@ async def create_users_with_list_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -756,7 +755,7 @@ async def create_users_with_list_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -776,16 +775,16 @@ def _create_users_with_list_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -814,7 +813,7 @@ def _create_users_with_list_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -842,14 +841,14 @@ async def delete_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete user
@@ -888,7 +887,7 @@ async def delete_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -910,14 +909,14 @@ async def delete_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete user
@@ -956,7 +955,7 @@ async def delete_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -978,14 +977,14 @@ async def delete_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete user
@@ -1024,7 +1023,7 @@ async def delete_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1046,15 +1045,15 @@ def _delete_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1070,7 +1069,7 @@ def _delete_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1098,14 +1097,14 @@ async def get_user_by_name(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> User:
"""Get user by user name
@@ -1144,7 +1143,7 @@ async def get_user_by_name(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1167,14 +1166,14 @@ async def get_user_by_name_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[User]:
"""Get user by user name
@@ -1213,7 +1212,7 @@ async def get_user_by_name_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1236,14 +1235,14 @@ async def get_user_by_name_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Get user by user name
@@ -1282,7 +1281,7 @@ async def get_user_by_name_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1305,15 +1304,15 @@ def _get_user_by_name_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1337,7 +1336,7 @@ def _get_user_by_name_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1366,14 +1365,14 @@ async def login_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Logs user into the system
@@ -1415,7 +1414,7 @@ async def login_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1438,14 +1437,14 @@ async def login_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Logs user into the system
@@ -1487,7 +1486,7 @@ async def login_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1510,14 +1509,14 @@ async def login_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs user into the system
@@ -1559,7 +1558,7 @@ async def login_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1582,15 +1581,15 @@ def _login_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1620,7 +1619,7 @@ def _login_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1647,14 +1646,14 @@ async def logout_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Logs out current logged in user session
@@ -1690,7 +1689,7 @@ async def logout_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1709,14 +1708,14 @@ async def logout_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Logs out current logged in user session
@@ -1752,7 +1751,7 @@ async def logout_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1771,14 +1770,14 @@ async def logout_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs out current logged in user session
@@ -1814,7 +1813,7 @@ async def logout_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1833,15 +1832,15 @@ def _logout_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1855,7 +1854,7 @@ def _logout_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1884,14 +1883,14 @@ async def update_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updated user
@@ -1933,7 +1932,7 @@ async def update_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1956,14 +1955,14 @@ async def update_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updated user
@@ -2005,7 +2004,7 @@ async def update_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2028,14 +2027,14 @@ async def update_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updated user
@@ -2077,7 +2076,7 @@ async def update_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2100,15 +2099,15 @@ def _update_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2139,7 +2138,7 @@ def _update_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api_client.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api_client.py
index 3d0170779a39..2f401cf5112f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/api_client.py
@@ -23,7 +23,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from petstore_api.configuration import Configuration
@@ -40,7 +40,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -289,7 +289,7 @@ async def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -437,16 +437,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -481,7 +481,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -511,7 +511,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -545,7 +545,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -578,7 +578,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/configuration.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/configuration.py
index e6a976c640e9..bd36fe0ec9ca 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/configuration.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/configuration.py
@@ -17,7 +17,7 @@
import logging
from logging import FileHandler
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
@@ -29,7 +29,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -126,13 +126,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -266,16 +266,16 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
signing_info: Optional[HttpSigningConfiguration]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[Union[int, aiohttp_retry.RetryOptionsBase]] = None,
@@ -424,7 +424,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -667,7 +667,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -720,7 +720,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_any_type.py
index 19db20137bc4..8664dd11b01d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_any_type.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py
index e4e4dbe21dea..000ed8b46d5c 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.pet import Pet
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,10 +28,10 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
""" # noqa: E501
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
- __properties: ClassVar[List[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
+ __properties: ClassVar[list[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_object.py
index d23fd87e51f3..2f1556c5e9ec 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_with_description_only.py
index b1f42400b676..f12bbeaec7f8 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_with_description_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py
index 4793b8e4b3cd..560b3f978be5 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class AllOfSuperModel(BaseModel):
AllOfSuperModel
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- __properties: ClassVar[List[str]] = ["_name"]
+ __properties: ClassVar[list[str]] = ["_name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py
index 34e4c3dca7ea..265e904edc62 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.single_ref_type import SingleRefType
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class AllOfWithSingleRef(BaseModel):
""" # noqa: E501
username: Optional[StrictStr] = None
single_ref_type: Optional[SingleRefType] = Field(default=None, alias="SingleRefType")
- __properties: ClassVar[List[str]] = ["username", "SingleRefType"]
+ __properties: ClassVar[list[str]] = ["username", "SingleRefType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/animal.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/animal.py
index d2b83fbdb9d7..ac2ae713dd57 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/animal.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/animal.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class Animal(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: Optional[StrictStr] = 'red'
- __properties: ClassVar[List[str]] = ["className", "color"]
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class Animal(BaseModel):
__discriminator_property_name: ClassVar[str] = 'className'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Cat': 'Cat','Dog': 'Dog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[Cat, Dog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_color.py
index f6d277e79498..2039c0de8af9 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_color.py
@@ -18,30 +18,30 @@
import pprint
import re # noqa: F401
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import List, Optional
+from typing import Optional
from typing_extensions import Annotated
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- anyof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- anyof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Optional[Union[List[int], str]] = None
+ actual_instance: Optional[Union[list[int], str]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "List[int]", "str" }
+ any_of_schemas: set[str] = { "list[int]", "str" }
model_config = {
"validate_assignment": True,
@@ -62,13 +62,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.model_construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -82,12 +82,12 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -95,7 +95,7 @@ def from_json(cls, json_str: str) -> Self:
"""Returns the object represented by the json string"""
instance = cls.model_construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -104,7 +104,7 @@ def from_json(cls, json_str: str) -> Self:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -125,7 +125,7 @@ def from_json(cls, json_str: str) -> Self:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -139,7 +139,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_pig.py
index c949e136f415..0211d0291d94 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/any_of_pig.py
@@ -21,7 +21,7 @@
from typing import Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ any_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = {
"validate_assignment": True,
@@ -80,7 +80,7 @@ def actual_instance_must_validate_anyof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -117,7 +117,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py
index ffdae49f239b..96fb714aa6a2 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ArrayOfArrayOfModel(BaseModel):
"""
ArrayOfArrayOfModel
""" # noqa: E501
- another_property: Optional[List[List[Tag]]] = None
- __properties: ClassVar[List[str]] = ["another_property"]
+ another_property: Optional[list[list[Tag]]] = None
+ __properties: ClassVar[list[str]] = ["another_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py
index 3fb0fb5056f6..2440ba9502d9 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class ArrayOfArrayOfNumberOnly(BaseModel):
"""
ArrayOfArrayOfNumberOnly
""" # noqa: E501
- array_array_number: Optional[List[List[float]]] = Field(default=None, alias="ArrayArrayNumber")
- __properties: ClassVar[List[str]] = ["ArrayArrayNumber"]
+ array_array_number: Optional[list[list[float]]] = Field(default=None, alias="ArrayArrayNumber")
+ __properties: ClassVar[list[str]] = ["ArrayArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_map_model.py
index 3db556b3eb8a..c521f8806baf 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_map_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
""" # noqa: E501
- array_of_map_property: Optional[List[Dict[str, Tag]]] = None
- __properties: ClassVar[List[str]] = ["array_of_map_property"]
+ array_of_map_property: Optional[list[dict[str, Tag]]] = None
+ __properties: ClassVar[list[str]] = ["array_of_map_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py
index 12b045326e11..aa33e549cea6 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class ArrayOfNumberOnly(BaseModel):
"""
ArrayOfNumberOnly
""" # noqa: E501
- array_number: Optional[List[float]] = Field(default=None, alias="ArrayNumber")
- __properties: ClassVar[List[str]] = ["ArrayNumber"]
+ array_number: Optional[list[float]] = Field(default=None, alias="ArrayNumber")
+ __properties: ClassVar[list[str]] = ["ArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py
index b47021e9adb0..45cef2649e16 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.read_only_first import ReadOnlyFirst
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,11 +29,11 @@ class ArrayTest(BaseModel):
"""
ArrayTest
""" # noqa: E501
- array_of_string: Optional[Annotated[List[StrictStr], Field(min_length=0, max_length=3)]] = None
- array_of_nullable_float: Optional[List[Optional[float]]] = None
- array_array_of_integer: Optional[List[List[StrictInt]]] = None
- array_array_of_model: Optional[List[List[ReadOnlyFirst]]] = None
- __properties: ClassVar[List[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
+ array_of_string: Optional[Annotated[list[StrictStr], Field(min_length=0, max_length=3)]] = None
+ array_of_nullable_float: Optional[list[Optional[float]]] = None
+ array_array_of_integer: Optional[list[list[StrictInt]]] = None
+ array_array_of_model: Optional[list[list[ReadOnlyFirst]]] = None
+ __properties: ClassVar[list[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/base_discriminator.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/base_discriminator.py
index 3b8f10a664b0..39309c362424 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/base_discriminator.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/base_discriminator.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class BaseDiscriminator(BaseModel):
BaseDiscriminator
""" # noqa: E501
type_name: Optional[StrictStr] = Field(default=None, alias="_typeName")
- __properties: ClassVar[List[str]] = ["_typeName"]
+ __properties: ClassVar[list[str]] = ["_typeName"]
model_config = ConfigDict(
validate_by_name=True,
@@ -48,12 +48,12 @@ class BaseDiscriminator(BaseModel):
__discriminator_property_name: ClassVar[str] = '_typeName'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'string': 'PrimitiveString','Info': 'Info'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -95,7 +95,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py
index 9282af3ff24f..40a546d8797d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class BasquePig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: StrictStr
- __properties: ClassVar[List[str]] = ["className", "color"]
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of BasquePig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of BasquePig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py
index 46b35c700e2b..050d625ca382 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Bathing(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bathing from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bathing from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py
index f4af4f06f207..5f8e58f797c5 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class Capitalization(BaseModel):
capital_snake: Optional[StrictStr] = Field(default=None, alias="Capital_Snake")
sca_eth_flow_points: Optional[StrictStr] = Field(default=None, alias="SCA_ETH_Flow_Points")
att_name: Optional[StrictStr] = Field(default=None, description="Name of the pet ", alias="ATT_NAME")
- __properties: ClassVar[List[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
+ __properties: ClassVar[list[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Capitalization from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Capitalization from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py
index 8692ceebb9a6..9b7b2adcb9e8 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Cat(Animal):
Cat
""" # noqa: E501
declawed: Optional[StrictBool] = None
- __properties: ClassVar[List[str]] = ["className", "color", "declawed"]
+ __properties: ClassVar[list[str]] = ["className", "color", "declawed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Cat from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Cat from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py
index f7d60fe80c03..8853e6f7091f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: StrictStr
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py
index a7ea1daf778d..dbb656bf1c3b 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class CircularAllOfRef(BaseModel):
CircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- second_circular_all_of_ref: Optional[List[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
- __properties: ClassVar[List[str]] = ["_name", "secondCircularAllOfRef"]
+ second_circular_all_of_ref: Optional[list[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
+ __properties: ClassVar[list[str]] = ["_name", "secondCircularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py
index f43b0863da44..fdf20775b6fb 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class CircularReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[FirstRef] = None
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py
index 331958d9b209..d960c1a8a095 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ClassModel(BaseModel):
Model for testing model with \"_class\" property
""" # noqa: E501
var_class: Optional[StrictStr] = Field(default=None, alias="_class")
- __properties: ClassVar[List[str]] = ["_class"]
+ __properties: ClassVar[list[str]] = ["_class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ClassModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ClassModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py
index cdbddee56d31..c863b59bfae2 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Client(BaseModel):
Client
""" # noqa: E501
client: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["client"]
+ __properties: ClassVar[list[str]] = ["client"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Client from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Client from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/color.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/color.py
index bb740fb597d4..b3c3404d00f7 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/color.py
@@ -16,26 +16,26 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- oneof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- oneof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
- actual_instance: Optional[Union[List[int], str]] = None
- one_of_schemas: Set[str] = { "List[int]", "str" }
+ actual_instance: Optional[Union[list[int], str]] = None
+ one_of_schemas: set[str] = { "list[int]", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -61,13 +61,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.model_construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -81,15 +81,15 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -102,7 +102,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -111,7 +111,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -132,10 +132,10 @@ def from_json(cls, json_str: Optional[str]) -> Self:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -149,7 +149,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature.py
index e2af9fc33051..00fb74f97cc3 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature.py
@@ -19,9 +19,9 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
+from typing import Any, ClassVar, Union
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class Creature(BaseModel):
""" # noqa: E501
info: CreatureInfo
type: StrictStr
- __properties: ClassVar[List[str]] = ["info", "type"]
+ __properties: ClassVar[list[str]] = ["info", "type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class Creature(BaseModel):
__discriminator_property_name: ClassVar[str] = 'type'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Hunting__Dog': 'HuntingDog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -99,7 +99,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[HuntingDog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py
index 2488eca5d562..55f98c41bafd 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class CreatureInfo(BaseModel):
CreatureInfo
""" # noqa: E501
name: StrictStr
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CreatureInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CreatureInfo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py
index ed51566a659e..d21daeee771a 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class DanishPig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
size: StrictInt
- __properties: ClassVar[List[str]] = ["className", "size"]
+ __properties: ClassVar[list[str]] = ["className", "size"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DanishPig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DanishPig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py
index 0c09f54f0e91..970695f34904 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class DeprecatedObject(BaseModel):
DeprecatedObject
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py
index 987dae7f5c32..7589535b78c7 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from petstore_api.models.discriminator_all_of_super import DiscriminatorAllOfSuper
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class DiscriminatorAllOfSub(DiscriminatorAllOfSuper):
"""
DiscriminatorAllOfSub
""" # noqa: E501
- __properties: ClassVar[List[str]] = ["elementType"]
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_super.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_super.py
index 661015629f41..0ee5044289d5 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_super.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_super.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class DiscriminatorAllOfSuper(BaseModel):
DiscriminatorAllOfSuper
""" # noqa: E501
element_type: StrictStr = Field(alias="elementType")
- __properties: ClassVar[List[str]] = ["elementType"]
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -47,12 +47,12 @@ class DiscriminatorAllOfSuper(BaseModel):
__discriminator_property_name: ClassVar[str] = 'elementType'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'DiscriminatorAllOfSub': 'DiscriminatorAllOfSub'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -73,7 +73,7 @@ def from_json(cls, json_str: str) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py
index b8752a1f948f..e224d25a2f2d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Dog(Animal):
Dog
""" # noqa: E501
breed: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["className", "color", "breed"]
+ __properties: ClassVar[list[str]] = ["className", "color", "breed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Dog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Dog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py
index 19a8109a056d..0eb1efad96a3 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class DummyModel(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SelfReferenceModel] = None
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DummyModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DummyModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py
index d841ea10e5b8..674013ea3853 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class EnumArrays(BaseModel):
EnumArrays
""" # noqa: E501
just_symbol: Optional[StrictStr] = None
- array_enum: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["just_symbol", "array_enum"]
+ array_enum: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["just_symbol", "array_enum"]
@field_validator('just_symbol')
def just_symbol_validate_enum(cls, value):
@@ -73,7 +73,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_ref_with_default_value.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_ref_with_default_value.py
index 5c29c04aa7f2..34a7c741f695 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_ref_with_default_value.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_ref_with_default_value.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.data_output_format import DataOutputFormat
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class EnumRefWithDefaultValue(BaseModel):
EnumRefWithDefaultValue
""" # noqa: E501
report_format: Optional[DataOutputFormat] = DataOutputFormat.JSON
- __properties: ClassVar[List[str]] = ["report_format"]
+ __properties: ClassVar[list[str]] = ["report_format"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py
index 604194529754..a30cc7f681e5 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py
@@ -18,14 +18,14 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.enum_number_vendor_ext import EnumNumberVendorExt
from petstore_api.models.enum_string_vendor_ext import EnumStringVendorExt
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_default_value import OuterEnumDefaultValue
from petstore_api.models.outer_enum_integer import OuterEnumInteger
from petstore_api.models.outer_enum_integer_default_value import OuterEnumIntegerDefaultValue
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -46,7 +46,7 @@ class EnumTest(BaseModel):
outer_enum_integer_default_value: Optional[OuterEnumIntegerDefaultValue] = Field(default=OuterEnumIntegerDefaultValue.NUMBER_0, alias="outerEnumIntegerDefaultValue")
enum_number_vendor_ext: Optional[EnumNumberVendorExt] = Field(default=None, alias="enumNumberVendorExt")
enum_string_vendor_ext: Optional[EnumStringVendorExt] = Field(default=None, alias="enumStringVendorExt")
- __properties: ClassVar[List[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
+ __properties: ClassVar[list[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
@field_validator('enum_string')
def enum_string_validate_enum(cls, value):
@@ -136,7 +136,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -146,7 +146,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -162,7 +162,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py
index ce5a36f49afb..05071d38a190 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Feeding(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Feeding from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Feeding from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py
index 7d8d010f8c82..0c3669e1b3ae 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class File(BaseModel):
Must be named `File` for test.
""" # noqa: E501
source_uri: Optional[StrictStr] = Field(default=None, description="Test capitalization", alias="sourceURI")
- __properties: ClassVar[List[str]] = ["sourceURI"]
+ __properties: ClassVar[list[str]] = ["sourceURI"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of File from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of File from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py
index 4c04c79dad7d..f22d55c60d88 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FileSchemaTestClass(BaseModel):
FileSchemaTestClass
""" # noqa: E501
file: Optional[File] = None
- files: Optional[List[File]] = None
- __properties: ClassVar[List[str]] = ["file", "files"]
+ files: Optional[list[File]] = None
+ __properties: ClassVar[list[str]] = ["file", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py
index 5c03477f15f0..e30d4a9fd320 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class FirstRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SecondRef] = None
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FirstRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FirstRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py
index 65a289e187de..187c197b8103 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Foo(BaseModel):
Foo
""" # noqa: E501
bar: Optional[StrictStr] = 'bar'
- __properties: ClassVar[List[str]] = ["bar"]
+ __properties: ClassVar[list[str]] = ["bar"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Foo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Foo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py
index e3a3f7a66aed..17e69ffc3f3c 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.foo import Foo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class FooGetDefaultResponse(BaseModel):
FooGetDefaultResponse
""" # noqa: E501
string: Optional[Foo] = None
- __properties: ClassVar[List[str]] = ["string"]
+ __properties: ClassVar[list[str]] = ["string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py
index c1314e23cbcf..b0599910e888 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py
@@ -20,10 +20,10 @@
from datetime import date, datetime
from decimal import Decimal
from pydantic import BaseModel, ConfigDict, Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional, Tuple, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -41,14 +41,14 @@ class FormatTest(BaseModel):
string: Optional[Annotated[str, Field(strict=True)]] = None
string_with_double_quote_pattern: Optional[Annotated[str, Field(strict=True)]] = None
byte: Optional[Union[StrictBytes, StrictStr]] = None
- binary: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None
+ binary: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None
var_date: date = Field(alias="date")
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
uuid: Optional[UUID] = None
password: Annotated[str, Field(min_length=10, strict=True, max_length=64)]
pattern_with_digits: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string that is a 10 digit number. Can have leading zeros.")
pattern_with_digits_and_delimiter: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.")
- __properties: ClassVar[List[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
+ __properties: ClassVar[list[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
@field_validator('string')
def string_validate_regular_expression(cls, value):
@@ -123,7 +123,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FormatTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -133,7 +133,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -144,7 +144,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FormatTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py
index c7a1c9f0913e..bce64615e695 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class HasOnlyReadOnly(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
foo: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["bar", "foo"]
+ __properties: ClassVar[list[str]] = ["bar", "foo"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"foo",
])
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py
index 270725757bad..8991a4da5ab8 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class HealthCheckResult(BaseModel):
Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model.
""" # noqa: E501
nullable_message: Optional[StrictStr] = Field(default=None, alias="NullableMessage")
- __properties: ClassVar[List[str]] = ["NullableMessage"]
+ __properties: ClassVar[list[str]] = ["NullableMessage"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py
index 4064ce67183c..5663af9615c0 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py
@@ -18,10 +18,10 @@
import json
from pydantic import ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature import Creature
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class HuntingDog(Creature):
HuntingDog
""" # noqa: E501
is_trained: Optional[StrictBool] = Field(default=None, alias="isTrained")
- __properties: ClassVar[List[str]] = ["info", "type", "isTrained"]
+ __properties: ClassVar[list[str]] = ["info", "type", "isTrained"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HuntingDog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HuntingDog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py
index 0f57b71af2aa..7ceff30f0e7a 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Info(BaseDiscriminator):
Info
""" # noqa: E501
val: Optional[BaseDiscriminator] = None
- __properties: ClassVar[List[str]] = ["_typeName", "val"]
+ __properties: ClassVar[list[str]] = ["_typeName", "val"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Info from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Info from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py
index 9b709fb15e43..a46bfbaac69f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
""" # noqa: E501
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
- __properties: ClassVar[List[str]] = ["aProperty"]
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
+ __properties: ClassVar[list[str]] = ["aProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py
index 2dd24cc67053..dd4d0f80a339 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class InputAllOf(BaseModel):
"""
InputAllOf
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InputAllOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InputAllOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/int_or_string.py
index f2a5a0a2d4a3..02180a2d6a53 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/int_or_string.py
@@ -16,10 +16,10 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -33,7 +33,7 @@ class IntOrString(BaseModel):
# data type: str
oneof_schema_2_validator: Optional[StrictStr] = None
actual_instance: Optional[Union[int, str]] = None
- one_of_schemas: Set[str] = { "int", "str" }
+ one_of_schemas: set[str] = { "int", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -78,7 +78,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -126,7 +126,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], int, str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], int, str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py
index 634b8d012d29..9a3397cadb19 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ListClass(BaseModel):
ListClass
""" # noqa: E501
var_123_list: Optional[StrictStr] = Field(default=None, alias="123-list")
- __properties: ClassVar[List[str]] = ["123-list"]
+ __properties: ClassVar[list[str]] = ["123-list"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ListClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ListClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py
index 8f8d882c67b3..ba6d3fa9a51f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
""" # noqa: E501
- shop_id_to_org_online_lip_map: Optional[Dict[str, List[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
- __properties: ClassVar[List[str]] = ["shopIdToOrgOnlineLipMap"]
+ shop_id_to_org_online_lip_map: Optional[dict[str, list[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ __properties: ClassVar[list[str]] = ["shopIdToOrgOnlineLipMap"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py
index ac4080efbc88..c1e7e7a2a2f7 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,11 +27,11 @@ class MapTest(BaseModel):
"""
MapTest
""" # noqa: E501
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
- __properties: ClassVar[List[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
+ __properties: ClassVar[list[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@field_validator('map_of_enum_string')
def map_of_enum_string_validate_enum(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
index f1ef7f55ead3..cb5739a124a0 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -19,10 +19,10 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,8 +32,8 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
""" # noqa: E501
uuid: Optional[UUID] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
- __properties: ClassVar[List[str]] = ["uuid", "dateTime", "map"]
+ map: Optional[dict[str, Animal]] = None
+ __properties: ClassVar[list[str]] = ["uuid", "dateTime", "map"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py
index 63c9faad21f5..cedb1a55999e 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Model200Response(BaseModel):
""" # noqa: E501
name: Optional[StrictInt] = None
var_class: Optional[StrictStr] = Field(default=None, alias="class")
- __properties: ClassVar[List[str]] = ["name", "class"]
+ __properties: ClassVar[list[str]] = ["name", "class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Model200Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Model200Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py
index 517441e5d545..172793ac34a9 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class ModelApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["code", "type", "message"]
+ __properties: ClassVar[list[str]] = ["code", "type", "message"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py
index 80951622bed4..52b053f77bd2 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ModelField(BaseModel):
ModelField
""" # noqa: E501
var_field: Optional[StrictStr] = Field(default=None, alias="field")
- __properties: ClassVar[List[str]] = ["field"]
+ __properties: ClassVar[list[str]] = ["field"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelField from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelField from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py
index 374b0b454781..10a15359c859 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ModelReturn(BaseModel):
Model for testing reserved words
""" # noqa: E501
var_return: Optional[StrictInt] = Field(default=None, alias="return")
- __properties: ClassVar[List[str]] = ["return"]
+ __properties: ClassVar[list[str]] = ["return"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelReturn from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelReturn from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py
index 0a3e337a950f..8f2c1c9647c0 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,9 +29,9 @@ class MultiArrays(BaseModel):
"""
MultiArrays
""" # noqa: E501
- tags: Optional[List[Tag]] = None
- files: Optional[List[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
- __properties: ClassVar[List[str]] = ["tags", "files"]
+ tags: Optional[list[Tag]] = None
+ files: Optional[list[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
+ __properties: ClassVar[list[str]] = ["tags", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MultiArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -89,7 +89,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MultiArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py
index 9b4f7a436ed6..7752ffa4d016 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class Name(BaseModel):
snake_case: Optional[StrictInt] = None
var_property: Optional[StrictStr] = Field(default=None, alias="property")
var_123_number: Optional[StrictInt] = Field(default=None, alias="123Number")
- __properties: ClassVar[List[str]] = ["name", "snake_case", "property", "123Number"]
+ __properties: ClassVar[list[str]] = ["name", "snake_case", "property", "123Number"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Name from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"snake_case",
"var_123_number",
])
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Name from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_class.py
index 25c6ba3d4d39..453cf7cc96e4 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_class.py
@@ -19,8 +19,8 @@
from datetime import date, datetime
from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,14 +35,14 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[List[Dict[str, Any]]] = None
- array_and_items_nullable_prop: Optional[List[Optional[Dict[str, Any]]]] = None
- array_items_nullable: Optional[List[Optional[Dict[str, Any]]]] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- object_items_nullable: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
+ array_nullable_prop: Optional[list[dict[str, Any]]] = None
+ array_and_items_nullable_prop: Optional[list[Optional[dict[str, Any]]]] = None
+ array_items_nullable: Optional[list[Optional[dict[str, Any]]]] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ object_items_nullable: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
model_config = ConfigDict(
validate_by_name=True,
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py
index f396a5f10045..d111fa5d0809 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class NullableProperty(BaseModel):
""" # noqa: E501
id: StrictInt
name: Optional[Annotated[str, Field(strict=True)]]
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
@field_validator('name')
def name_validate_regular_expression(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py
index b91b8d045003..39ebe490e2a3 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class NumberOnly(BaseModel):
NumberOnly
""" # noqa: E501
just_number: Optional[float] = Field(default=None, alias="JustNumber")
- __properties: ClassVar[List[str]] = ["JustNumber"]
+ __properties: ClassVar[list[str]] = ["JustNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py
index 2ac8a9d37a2c..ef52cbbec779 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ObjectToTestAdditionalProperties(BaseModel):
Minimal object
""" # noqa: E501
var_property: Optional[StrictBool] = Field(default=False, description="Property", alias="property")
- __properties: ClassVar[List[str]] = ["property"]
+ __properties: ClassVar[list[str]] = ["property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py
index e3bae640cdb7..1a65ab0a2c2c 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.deprecated_object import DeprecatedObject
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class ObjectWithDeprecatedFields(BaseModel):
uuid: Optional[StrictStr] = None
id: Optional[float] = None
deprecated_ref: Optional[DeprecatedObject] = Field(default=None, alias="deprecatedRef")
- bars: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["uuid", "id", "deprecatedRef", "bars"]
+ bars: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["uuid", "id", "deprecatedRef", "bars"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py
index 0cd26ab72b34..5669dbddac50 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py
@@ -19,8 +19,8 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- __properties: ClassVar[List[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
+ __properties: ClassVar[list[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Order from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Order from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py
index 05186f8015e6..196dc5d62837 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class OuterComposite(BaseModel):
my_number: Optional[float] = None
my_string: Optional[StrictStr] = None
my_boolean: Optional[StrictBool] = None
- __properties: ClassVar[List[str]] = ["my_number", "my_string", "my_boolean"]
+ __properties: ClassVar[list[str]] = ["my_number", "my_string", "my_boolean"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterComposite from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterComposite from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py
index b73faea2c909..8a6e80dcbd7c 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_integer import OuterEnumInteger
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class OuterObjectWithEnumProperty(BaseModel):
""" # noqa: E501
str_value: Optional[OuterEnum] = None
value: OuterEnumInteger
- __properties: ClassVar[List[str]] = ["str_value", "value"]
+ __properties: ClassVar[list[str]] = ["str_value", "value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py
index b8a5de498efe..f66cfd2450a3 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Parent(BaseModel):
"""
Parent
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Parent from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Parent from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py
index 5193e6750c1f..85eba221c11f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py
index 4543f973c33d..3735eccc8041 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py
@@ -18,11 +18,11 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,10 +33,10 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
category: Optional[Category] = None
name: StrictStr
- photo_urls: Annotated[List[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: Annotated[list[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- __properties: ClassVar[List[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
+ __properties: ClassVar[list[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -69,7 +69,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pig.py
index b3a759e89b7b..84990e6d521b 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pig.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -34,7 +34,7 @@ class Pig(BaseModel):
# data type: DanishPig
oneof_schema_2_validator: Optional[DanishPig] = None
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
- one_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ one_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = ConfigDict(
validate_assignment=True,
@@ -42,7 +42,7 @@ class Pig(BaseModel):
)
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
}
def __init__(self, *args, **kwargs) -> None:
@@ -80,7 +80,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -122,7 +122,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py
index c70683def48d..60bab06703a0 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.type import Type
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class PonySizes(BaseModel):
PonySizes
""" # noqa: E501
type: Optional[Type] = None
- __properties: ClassVar[List[str]] = ["type"]
+ __properties: ClassVar[list[str]] = ["type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PonySizes from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PonySizes from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py
index 3733c7bd9b00..83e3dd925c39 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class PoopCleaning(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PoopCleaning from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PoopCleaning from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py
index f23b8503d855..aa5a70e798ee 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class PrimitiveString(BaseDiscriminator):
PrimitiveString
""" # noqa: E501
value: Optional[StrictStr] = Field(default=None, alias="_value")
- __properties: ClassVar[List[str]] = ["_typeName", "_value"]
+ __properties: ClassVar[list[str]] = ["_typeName", "_value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PrimitiveString from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PrimitiveString from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py
index d48ade5d9984..d07c9fa2b197 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class PropertyMap(BaseModel):
"""
PropertyMap
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyMap from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyMap from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py
index edae9c5f2c1d..83341f6717ff 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class PropertyNameCollision(BaseModel):
underscore_type: Optional[StrictStr] = Field(default=None, alias="_type")
type: Optional[StrictStr] = None
type_with_underscore: Optional[StrictStr] = Field(default=None, alias="type_")
- __properties: ClassVar[List[str]] = ["_type", "type", "type_"]
+ __properties: ClassVar[list[str]] = ["_type", "type", "type_"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py
index e22fac10b2b5..3b646e20bc56 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class ReadOnlyFirst(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
baz: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["bar", "baz"]
+ __properties: ClassVar[list[str]] = ["bar", "baz"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
])
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py
index b56e8782933e..3de9334565ef 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class SecondCircularAllOfRef(BaseModel):
SecondCircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- circular_all_of_ref: Optional[List[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
- __properties: ClassVar[List[str]] = ["_name", "circularAllOfRef"]
+ circular_all_of_ref: Optional[list[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
+ __properties: ClassVar[list[str]] = ["_name", "circularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py
index 69eb99fad636..38c5746c117d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class SecondRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
circular_ref: Optional[CircularReferenceModel] = None
- __properties: ClassVar[List[str]] = ["category", "circular_ref"]
+ __properties: ClassVar[list[str]] = ["category", "circular_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py
index fb84a0573dba..565cd5555100 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class SelfReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[DummyModel] = None
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py
index 4188827e69e7..c3686f934651 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class SpecialModelName(BaseModel):
SpecialModelName
""" # noqa: E501
special_property_name: Optional[StrictInt] = Field(default=None, alias="$special[property.name]")
- __properties: ClassVar[List[str]] = ["$special[property.name]"]
+ __properties: ClassVar[list[str]] = ["$special[property.name]"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialModelName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialModelName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py
index 432acdbdb90a..21ca42a8859f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.category import Category
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class SpecialName(BaseModel):
var_property: Optional[StrictInt] = Field(default=None, alias="property")
var_async: Optional[Category] = Field(default=None, alias="async")
var_schema: Optional[StrictStr] = Field(default=None, description="pet status in the store", alias="schema")
- __properties: ClassVar[List[str]] = ["property", "async", "schema"]
+ __properties: ClassVar[list[str]] = ["property", "async", "schema"]
@field_validator('var_schema')
def var_schema_validate_enum(cls, value):
@@ -64,7 +64,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py
index 5dbba0015e8b..48feecf53518 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py
index e926f4c275d5..a987c90a464d 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from uuid import UUID
from petstore_api.models.task_activity import TaskActivity
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class Task(BaseModel):
""" # noqa: E501
id: UUID
activity: TaskActivity
- __properties: ClassVar[List[str]] = ["id", "activity"]
+ __properties: ClassVar[list[str]] = ["id", "activity"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Task from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -78,7 +78,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Task from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task_activity.py
index cc1e1fc5a60f..51bec8a6c3f0 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task_activity.py
@@ -16,12 +16,12 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -37,7 +37,7 @@ class TaskActivity(BaseModel):
# data type: Bathing
oneof_schema_3_validator: Optional[Bathing] = None
actual_instance: Optional[Union[Bathing, Feeding, PoopCleaning]] = None
- one_of_schemas: Set[str] = { "Bathing", "Feeding", "PoopCleaning" }
+ one_of_schemas: set[str] = { "Bathing", "Feeding", "PoopCleaning" }
model_config = ConfigDict(
validate_assignment=True,
@@ -85,7 +85,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -133,7 +133,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], Bathing, Feeding, PoopCleaning]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], Bathing, Feeding, PoopCleaning]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py
index 6f4bba183ee4..2a4287ffe603 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestErrorResponsesWithModel400Response(BaseModel):
TestErrorResponsesWithModel400Response
""" # noqa: E501
reason400: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["reason400"]
+ __properties: ClassVar[list[str]] = ["reason400"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py
index 16b242b56b71..3d6b01a887d4 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestErrorResponsesWithModel404Response(BaseModel):
TestErrorResponsesWithModel404Response
""" # noqa: E501
reason404: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["reason404"]
+ __properties: ClassVar[list[str]] = ["reason404"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 67f893c75448..2ba526ab52ba 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
""" # noqa: E501
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["someProperty"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["someProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py
index 65d891895df5..08c8cf85ae14 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.test_enum import TestEnum
from petstore_api.models.test_enum_with_default import TestEnumWithDefault
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class TestModelWithEnumDefault(BaseModel):
test_enum_with_default: Optional[TestEnumWithDefault] = TestEnumWithDefault.ZWEI
test_string_with_default: Optional[StrictStr] = 'ahoy matey'
test_inline_defined_enum_with_default: Optional[StrictStr] = 'B'
- __properties: ClassVar[List[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
+ __properties: ClassVar[list[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
@field_validator('test_inline_defined_enum_with_default')
def test_inline_defined_enum_with_default_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py
index e1b5959f69d1..fcb8b131f86f 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestObjectForMultipartRequestsRequestMarker(BaseModel):
TestObjectForMultipartRequestsRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py
index c1f7eebcb138..bb3f2bc18bff 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Tiger(BaseModel):
Tiger
""" # noqa: E501
skill: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["skill"]
+ __properties: ClassVar[list[str]] = ["skill"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tiger from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tiger from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index 4c79fe8bc7e5..2ab6e7027639 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[CreatureInfo]]] = Field(default=None, alias="dictProperty")
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[CreatureInfo]]] = Field(default=None, alias="dictProperty")
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index 78d19e89e0e7..3e77e43d2972 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[StrictStr]]] = Field(default=None, alias="dictProperty")
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[StrictStr]]] = Field(default=None, alias="dictProperty")
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py
index 02ccb0a8c689..4105e790cab7 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
Additional object
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py
index 624e5c2135c4..99e4ddb8e98e 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, description="User Status", alias="userStatus")
- __properties: ClassVar[List[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
+ __properties: ClassVar[list[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
model_config = ConfigDict(
validate_by_name=True,
@@ -58,7 +58,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of User from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of User from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/uuid_with_pattern.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/uuid_with_pattern.py
index 9936e04769f1..8bb2d8099be8 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/uuid_with_pattern.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/uuid_with_pattern.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class UuidWithPattern(BaseModel):
UuidWithPattern
""" # noqa: E501
id: Optional[UUID] = None
- __properties: ClassVar[List[str]] = ["id"]
+ __properties: ClassVar[list[str]] = ["id"]
@field_validator('id')
def id_validate_regular_expression(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py
index 4f2003d80cc3..95a89ced47f5 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.one_of_enum_string import OneOfEnumString
from petstore_api.models.pig import Pig
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class WithNestedOneOf(BaseModel):
size: Optional[StrictInt] = None
nested_pig: Optional[Pig] = None
nested_oneof_enum_string: Optional[OneOfEnumString] = None
- __properties: ClassVar[List[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
+ __properties: ClassVar[list[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/signing.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/signing.py
index e0ef058f4677..c52fe689fc96 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/signing.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/signing.py
@@ -22,7 +22,7 @@
import os
import re
from time import time
-from typing import List, Optional, Union
+from typing import Optional, Union
from urllib.parse import urlencode, urlparse
# The constants below define a subset of HTTP headers that can be included in the
@@ -128,7 +128,7 @@ def __init__(self,
signing_scheme: str,
private_key_path: str,
private_key_passphrase: Union[None, str]=None,
- signed_headers: Optional[List[str]]=None,
+ signed_headers: Optional[list[str]]=None,
signing_algorithm: Optional[str]=None,
hash_algorithm: Optional[str]=None,
signature_max_validity: Optional[timedelta]=None,
diff --git a/samples/openapi3/client/petstore/python-aiohttp/tests/test_model.py b/samples/openapi3/client/petstore/python-aiohttp/tests/test_model.py
index 0ef8d9956a78..3a527b5139df 100644
--- a/samples/openapi3/client/petstore/python-aiohttp/tests/test_model.py
+++ b/samples/openapi3/client/petstore/python-aiohttp/tests/test_model.py
@@ -190,7 +190,7 @@ def test_list(self):
self.assertTrue(False) # this line shouldn't execute
except ValueError as e:
#error_message = (
- # "1 validation error for List\n"
+ # "1 validation error for list\n"
# "123-list\n"
# " str type expected (type=type_error.str)\n")
self.assertTrue("str type expected" in str(e))
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-httpx/docs/AdditionalPropertiesClass.md
index 5128004d8f9a..faa22e6e6b1b 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/AdditionalPropertiesClass.md
@@ -5,9 +5,9 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfModel.md
index f866863d53f9..13c6bc20804d 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfNumberOnly.md
index 32bd2dfbf1e2..8fa0d5954ad1 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfMapModel.md
index fd39f86fce5e..44ee01bb37b6 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfMapModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfNumberOnly.md
index b814d7594942..bc690d09040a 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ArrayTest.md b/samples/openapi3/client/petstore/python-httpx/docs/ArrayTest.md
index ed871fae662d..014e64472c22 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ArrayTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[Optional[float]]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[Optional[float]]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python-httpx/docs/CircularAllOfRef.md
index 65b171177e58..d39dfe136b9f 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/CircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/EnumArrays.md b/samples/openapi3/client/petstore/python-httpx/docs/EnumArrays.md
index f44617497bce..687172987bc6 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/EnumArrays.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/FakeApi.md b/samples/openapi3/client/petstore/python-httpx/docs/FakeApi.md
index 8f79394afc28..a69ca16e828d 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/FakeApi.md
@@ -651,7 +651,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = await api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -669,7 +669,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1121,7 +1121,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1163,7 +1163,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1393,7 +1393,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1409,7 +1409,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2093,7 +2093,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2109,7 +2109,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2350,13 +2350,13 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
await api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2371,13 +2371,13 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2426,7 +2426,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2442,7 +2442,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python-httpx/docs/FileSchemaTestClass.md
index e1118042a8ec..aae04a5bbba7 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/FileSchemaTestClass.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/InputAllOf.md b/samples/openapi3/client/petstore/python-httpx/docs/InputAllOf.md
index 45298f5308fc..adc4f9cdcb63 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/InputAllOf.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python-httpx/docs/MapOfArrayOfModel.md
index 71a4ef66b682..d2a7c41b46f9 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/MapOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/MapTest.md b/samples/openapi3/client/petstore/python-httpx/docs/MapTest.md
index d04b82e9378c..33032142168b 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/MapTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-httpx/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 84134317aefc..7e5fb0b3071d 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **UUID** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/MultiArrays.md b/samples/openapi3/client/petstore/python-httpx/docs/MultiArrays.md
index fea5139e7e73..62398cd42693 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/MultiArrays.md
@@ -5,8 +5,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/NullableClass.md b/samples/openapi3/client/petstore/python-httpx/docs/NullableClass.md
index 0387dcc2c67a..1378ee707136 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/NullableClass.md
@@ -12,12 +12,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[Optional[object]]** | | [optional]
-**array_items_nullable** | **List[Optional[object]]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, Optional[object]]** | | [optional]
-**object_items_nullable** | **Dict[str, Optional[object]]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[Optional[object]]** | | [optional]
+**array_items_nullable** | **list[Optional[object]]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, Optional[object]]** | | [optional]
+**object_items_nullable** | **dict[str, Optional[object]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python-httpx/docs/ObjectWithDeprecatedFields.md
index 6dbd2ace04f1..fcdff0bdf060 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ObjectWithDeprecatedFields.md
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/Parent.md b/samples/openapi3/client/petstore/python-httpx/docs/Parent.md
index 7387f9250aad..56fbac8cbb28 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/Parent.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python-httpx/docs/ParentWithOptionalDict.md
index bfc8688ea26f..7d278755c08f 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/ParentWithOptionalDict.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/Pet.md b/samples/openapi3/client/petstore/python-httpx/docs/Pet.md
index 5329cf2fb925..14d1e224a08a 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/PetApi.md b/samples/openapi3/client/petstore/python-httpx/docs/PetApi.md
index 4dda39306a29..478ac90eeb82 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/PetApi.md
@@ -228,7 +228,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -324,7 +324,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -342,11 +342,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -367,7 +367,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -463,7 +463,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -481,11 +481,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/PropertyMap.md b/samples/openapi3/client/petstore/python-httpx/docs/PropertyMap.md
index a55a0e5c6f01..0c32115e8200 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/PropertyMap.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python-httpx/docs/SecondCircularAllOfRef.md
index 65ebdd4c7e1d..894564db2594 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/SecondCircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/StoreApi.md b/samples/openapi3/client/petstore/python-httpx/docs/StoreApi.md
index 27f240911fcb..eb1367bf4d1b 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/StoreApi.md
@@ -77,7 +77,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -131,7 +131,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalModelListProperties.md
index 68cd00ab0a7a..dbf6ee475056 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalStringListProperties.md
index 045b0e22ad09..f9bf8d7b3489 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-httpx/docs/UserApi.md b/samples/openapi3/client/petstore/python-httpx/docs/UserApi.md
index 5bb4ccfdf228..2ce4b6e4fa2f 100644
--- a/samples/openapi3/client/petstore/python-httpx/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python-httpx/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -123,7 +123,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -173,7 +173,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -189,7 +189,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/another_fake_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/another_fake_api.py
index 9ceb307bbb24..aff4e8f9ad04 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/another_fake_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/another_fake_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ async def call_123_test_special_tags(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test special tags
@@ -90,7 +90,7 @@ async def call_123_test_special_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -111,14 +111,14 @@ async def call_123_test_special_tags_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test special tags
@@ -157,7 +157,7 @@ async def call_123_test_special_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -178,14 +178,14 @@ async def call_123_test_special_tags_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test special tags
@@ -224,7 +224,7 @@ async def call_123_test_special_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -245,15 +245,15 @@ def _call_123_test_special_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _call_123_test_special_tags_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/default_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/default_api.py
index 13aec70c14ed..ae9cdb4faaf6 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/default_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/default_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from petstore_api.models.foo_get_default_response import FooGetDefaultResponse
@@ -41,14 +41,14 @@ async def foo_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> FooGetDefaultResponse:
"""foo_get
@@ -83,7 +83,7 @@ async def foo_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -102,14 +102,14 @@ async def foo_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[FooGetDefaultResponse]:
"""foo_get
@@ -144,7 +144,7 @@ async def foo_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -163,14 +163,14 @@ async def foo_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""foo_get
@@ -205,7 +205,7 @@ async def foo_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -224,15 +224,15 @@ def _foo_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -253,7 +253,7 @@ def _foo_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_api.py
index 9e895f7806ee..2380caae8a1a 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_api.py
@@ -12,12 +12,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
from petstore_api.models.client import Client
@@ -56,18 +56,18 @@ def __init__(self, api_client=None) -> None:
@validate_call
async def fake_any_type_request_body(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test any type request body
@@ -105,7 +105,7 @@ async def fake_any_type_request_body(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -122,18 +122,18 @@ async def fake_any_type_request_body(
@validate_call
async def fake_any_type_request_body_with_http_info(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test any type request body
@@ -171,7 +171,7 @@ async def fake_any_type_request_body_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -188,18 +188,18 @@ async def fake_any_type_request_body_with_http_info(
@validate_call
async def fake_any_type_request_body_without_preload_content(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test any type request body
@@ -237,7 +237,7 @@ async def fake_any_type_request_body_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -258,15 +258,15 @@ def _fake_any_type_request_body_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -295,7 +295,7 @@ def _fake_any_type_request_body_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -323,14 +323,14 @@ async def fake_enum_ref_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test enum reference query parameter
@@ -368,7 +368,7 @@ async def fake_enum_ref_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -389,14 +389,14 @@ async def fake_enum_ref_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test enum reference query parameter
@@ -434,7 +434,7 @@ async def fake_enum_ref_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -455,14 +455,14 @@ async def fake_enum_ref_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum reference query parameter
@@ -500,7 +500,7 @@ async def fake_enum_ref_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -521,15 +521,15 @@ def _fake_enum_ref_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -547,7 +547,7 @@ def _fake_enum_ref_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,14 +574,14 @@ async def fake_health_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> HealthCheckResult:
"""Health check endpoint
@@ -616,7 +616,7 @@ async def fake_health_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -636,14 +636,14 @@ async def fake_health_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[HealthCheckResult]:
"""Health check endpoint
@@ -678,7 +678,7 @@ async def fake_health_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -698,14 +698,14 @@ async def fake_health_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Health check endpoint
@@ -740,7 +740,7 @@ async def fake_health_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = await self.api_client.call_api(
@@ -760,15 +760,15 @@ def _fake_health_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -789,7 +789,7 @@ def _fake_health_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -819,14 +819,14 @@ async def fake_http_signature_test(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test http signature authentication
@@ -870,7 +870,7 @@ async def fake_http_signature_test(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -893,14 +893,14 @@ async def fake_http_signature_test_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test http signature authentication
@@ -944,7 +944,7 @@ async def fake_http_signature_test_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -967,14 +967,14 @@ async def fake_http_signature_test_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test http signature authentication
@@ -1018,7 +1018,7 @@ async def fake_http_signature_test_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -1041,15 +1041,15 @@ def _fake_http_signature_test_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1085,7 +1085,7 @@ def _fake_http_signature_test_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_signature_test'
]
@@ -1114,14 +1114,14 @@ async def fake_outer_boolean_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""fake_outer_boolean_serialize
@@ -1160,7 +1160,7 @@ async def fake_outer_boolean_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1181,14 +1181,14 @@ async def fake_outer_boolean_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""fake_outer_boolean_serialize
@@ -1227,7 +1227,7 @@ async def fake_outer_boolean_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1248,14 +1248,14 @@ async def fake_outer_boolean_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_boolean_serialize
@@ -1294,7 +1294,7 @@ async def fake_outer_boolean_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -1315,15 +1315,15 @@ def _fake_outer_boolean_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1359,7 +1359,7 @@ def _fake_outer_boolean_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1387,14 +1387,14 @@ async def fake_outer_composite_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterComposite:
"""fake_outer_composite_serialize
@@ -1433,7 +1433,7 @@ async def fake_outer_composite_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1454,14 +1454,14 @@ async def fake_outer_composite_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterComposite]:
"""fake_outer_composite_serialize
@@ -1500,7 +1500,7 @@ async def fake_outer_composite_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1521,14 +1521,14 @@ async def fake_outer_composite_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_composite_serialize
@@ -1567,7 +1567,7 @@ async def fake_outer_composite_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = await self.api_client.call_api(
@@ -1588,15 +1588,15 @@ def _fake_outer_composite_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1632,7 +1632,7 @@ def _fake_outer_composite_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1660,14 +1660,14 @@ async def fake_outer_number_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""fake_outer_number_serialize
@@ -1706,7 +1706,7 @@ async def fake_outer_number_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1727,14 +1727,14 @@ async def fake_outer_number_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""fake_outer_number_serialize
@@ -1773,7 +1773,7 @@ async def fake_outer_number_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1794,14 +1794,14 @@ async def fake_outer_number_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_number_serialize
@@ -1840,7 +1840,7 @@ async def fake_outer_number_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -1861,15 +1861,15 @@ def _fake_outer_number_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1905,7 +1905,7 @@ def _fake_outer_number_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1933,14 +1933,14 @@ async def fake_outer_string_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""fake_outer_string_serialize
@@ -1979,7 +1979,7 @@ async def fake_outer_string_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2000,14 +2000,14 @@ async def fake_outer_string_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""fake_outer_string_serialize
@@ -2046,7 +2046,7 @@ async def fake_outer_string_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2067,14 +2067,14 @@ async def fake_outer_string_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_string_serialize
@@ -2113,7 +2113,7 @@ async def fake_outer_string_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -2134,15 +2134,15 @@ def _fake_outer_string_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2178,7 +2178,7 @@ def _fake_outer_string_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2203,18 +2203,18 @@ def _fake_outer_string_serialize_serialize(
async def fake_property_enum_integer_serialize(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterObjectWithEnumProperty:
"""fake_property_enum_integer_serialize
@@ -2224,7 +2224,7 @@ async def fake_property_enum_integer_serialize(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2256,7 +2256,7 @@ async def fake_property_enum_integer_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2274,18 +2274,18 @@ async def fake_property_enum_integer_serialize(
async def fake_property_enum_integer_serialize_with_http_info(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterObjectWithEnumProperty]:
"""fake_property_enum_integer_serialize
@@ -2295,7 +2295,7 @@ async def fake_property_enum_integer_serialize_with_http_info(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2327,7 +2327,7 @@ async def fake_property_enum_integer_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2345,18 +2345,18 @@ async def fake_property_enum_integer_serialize_with_http_info(
async def fake_property_enum_integer_serialize_without_preload_content(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_property_enum_integer_serialize
@@ -2366,7 +2366,7 @@ async def fake_property_enum_integer_serialize_without_preload_content(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2398,7 +2398,7 @@ async def fake_property_enum_integer_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = await self.api_client.call_api(
@@ -2420,16 +2420,16 @@ def _fake_property_enum_integer_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'param': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2469,7 +2469,7 @@ def _fake_property_enum_integer_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2496,14 +2496,14 @@ async def fake_ref_enum_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> EnumClass:
"""test ref to enum string
@@ -2538,7 +2538,7 @@ async def fake_ref_enum_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2558,14 +2558,14 @@ async def fake_ref_enum_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[EnumClass]:
"""test ref to enum string
@@ -2600,7 +2600,7 @@ async def fake_ref_enum_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2620,14 +2620,14 @@ async def fake_ref_enum_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test ref to enum string
@@ -2662,7 +2662,7 @@ async def fake_ref_enum_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = await self.api_client.call_api(
@@ -2682,15 +2682,15 @@ def _fake_ref_enum_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2711,7 +2711,7 @@ def _fake_ref_enum_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2738,14 +2738,14 @@ async def fake_return_boolean(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""test returning boolean
@@ -2780,7 +2780,7 @@ async def fake_return_boolean(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2800,14 +2800,14 @@ async def fake_return_boolean_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""test returning boolean
@@ -2842,7 +2842,7 @@ async def fake_return_boolean_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2862,14 +2862,14 @@ async def fake_return_boolean_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning boolean
@@ -2904,7 +2904,7 @@ async def fake_return_boolean_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = await self.api_client.call_api(
@@ -2924,15 +2924,15 @@ def _fake_return_boolean_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2953,7 +2953,7 @@ def _fake_return_boolean_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2980,14 +2980,14 @@ async def fake_return_byte_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""test byte like json
@@ -3022,7 +3022,7 @@ async def fake_return_byte_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3042,14 +3042,14 @@ async def fake_return_byte_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""test byte like json
@@ -3084,7 +3084,7 @@ async def fake_return_byte_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3104,14 +3104,14 @@ async def fake_return_byte_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test byte like json
@@ -3146,7 +3146,7 @@ async def fake_return_byte_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = await self.api_client.call_api(
@@ -3166,15 +3166,15 @@ def _fake_return_byte_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3195,7 +3195,7 @@ def _fake_return_byte_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3222,14 +3222,14 @@ async def fake_return_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning enum
@@ -3264,7 +3264,7 @@ async def fake_return_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3284,14 +3284,14 @@ async def fake_return_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning enum
@@ -3326,7 +3326,7 @@ async def fake_return_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3346,14 +3346,14 @@ async def fake_return_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning enum
@@ -3388,7 +3388,7 @@ async def fake_return_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3408,15 +3408,15 @@ def _fake_return_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3437,7 +3437,7 @@ def _fake_return_enum_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3464,14 +3464,14 @@ async def fake_return_enum_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test enum like json
@@ -3506,7 +3506,7 @@ async def fake_return_enum_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3526,14 +3526,14 @@ async def fake_return_enum_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test enum like json
@@ -3568,7 +3568,7 @@ async def fake_return_enum_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3588,14 +3588,14 @@ async def fake_return_enum_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum like json
@@ -3630,7 +3630,7 @@ async def fake_return_enum_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -3650,15 +3650,15 @@ def _fake_return_enum_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3679,7 +3679,7 @@ def _fake_return_enum_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3706,14 +3706,14 @@ async def fake_return_float(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""test returning float
@@ -3748,7 +3748,7 @@ async def fake_return_float(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3768,14 +3768,14 @@ async def fake_return_float_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""test returning float
@@ -3810,7 +3810,7 @@ async def fake_return_float_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3830,14 +3830,14 @@ async def fake_return_float_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning float
@@ -3872,7 +3872,7 @@ async def fake_return_float_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = await self.api_client.call_api(
@@ -3892,15 +3892,15 @@ def _fake_return_float_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3921,7 +3921,7 @@ def _fake_return_float_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3948,14 +3948,14 @@ async def fake_return_int(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> int:
"""test returning int
@@ -3990,7 +3990,7 @@ async def fake_return_int(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4010,14 +4010,14 @@ async def fake_return_int_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[int]:
"""test returning int
@@ -4052,7 +4052,7 @@ async def fake_return_int_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4072,14 +4072,14 @@ async def fake_return_int_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning int
@@ -4114,7 +4114,7 @@ async def fake_return_int_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = await self.api_client.call_api(
@@ -4134,15 +4134,15 @@ def _fake_return_int_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4163,7 +4163,7 @@ def _fake_return_int_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4190,16 +4190,16 @@ async def fake_return_list_of_objects(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[List[Tag]]:
+ ) -> list[list[Tag]]:
"""test returning list of objects
@@ -4232,8 +4232,8 @@ async def fake_return_list_of_objects(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4252,16 +4252,16 @@ async def fake_return_list_of_objects_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[List[Tag]]]:
+ ) -> ApiResponse[list[list[Tag]]]:
"""test returning list of objects
@@ -4294,8 +4294,8 @@ async def fake_return_list_of_objects_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4314,14 +4314,14 @@ async def fake_return_list_of_objects_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning list of objects
@@ -4356,8 +4356,8 @@ async def fake_return_list_of_objects_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -4376,15 +4376,15 @@ def _fake_return_list_of_objects_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4405,7 +4405,7 @@ def _fake_return_list_of_objects_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4432,14 +4432,14 @@ async def fake_return_str_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test str like json
@@ -4474,7 +4474,7 @@ async def fake_return_str_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4494,14 +4494,14 @@ async def fake_return_str_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test str like json
@@ -4536,7 +4536,7 @@ async def fake_return_str_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4556,14 +4556,14 @@ async def fake_return_str_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test str like json
@@ -4598,7 +4598,7 @@ async def fake_return_str_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4618,15 +4618,15 @@ def _fake_return_str_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4647,7 +4647,7 @@ def _fake_return_str_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4674,14 +4674,14 @@ async def fake_return_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning string
@@ -4716,7 +4716,7 @@ async def fake_return_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4736,14 +4736,14 @@ async def fake_return_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning string
@@ -4778,7 +4778,7 @@ async def fake_return_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4798,14 +4798,14 @@ async def fake_return_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning string
@@ -4840,7 +4840,7 @@ async def fake_return_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = await self.api_client.call_api(
@@ -4860,15 +4860,15 @@ def _fake_return_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4889,7 +4889,7 @@ def _fake_return_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4917,14 +4917,14 @@ async def fake_uuid_example(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test uuid example
@@ -4962,7 +4962,7 @@ async def fake_uuid_example(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -4983,14 +4983,14 @@ async def fake_uuid_example_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test uuid example
@@ -5028,7 +5028,7 @@ async def fake_uuid_example_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5049,14 +5049,14 @@ async def fake_uuid_example_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test uuid example
@@ -5094,7 +5094,7 @@ async def fake_uuid_example_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5115,15 +5115,15 @@ def _fake_uuid_example_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5141,7 +5141,7 @@ def _fake_uuid_example_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5165,18 +5165,18 @@ def _fake_uuid_example_serialize(
@validate_call
async def test_additional_properties_reference(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced additionalProperties
@@ -5184,7 +5184,7 @@ async def test_additional_properties_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5215,7 +5215,7 @@ async def test_additional_properties_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5232,18 +5232,18 @@ async def test_additional_properties_reference(
@validate_call
async def test_additional_properties_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced additionalProperties
@@ -5251,7 +5251,7 @@ async def test_additional_properties_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5282,7 +5282,7 @@ async def test_additional_properties_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5299,18 +5299,18 @@ async def test_additional_properties_reference_with_http_info(
@validate_call
async def test_additional_properties_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced additionalProperties
@@ -5318,7 +5318,7 @@ async def test_additional_properties_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5349,7 +5349,7 @@ async def test_additional_properties_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5370,15 +5370,15 @@ def _test_additional_properties_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5407,7 +5407,7 @@ def _test_additional_properties_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5431,18 +5431,18 @@ def _test_additional_properties_reference_serialize(
@validate_call
async def test_body_with_binary(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_binary
@@ -5481,7 +5481,7 @@ async def test_body_with_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5498,18 +5498,18 @@ async def test_body_with_binary(
@validate_call
async def test_body_with_binary_with_http_info(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_binary
@@ -5548,7 +5548,7 @@ async def test_body_with_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5565,18 +5565,18 @@ async def test_body_with_binary_with_http_info(
@validate_call
async def test_body_with_binary_without_preload_content(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_binary
@@ -5615,7 +5615,7 @@ async def test_body_with_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5636,15 +5636,15 @@ def _test_body_with_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5681,7 +5681,7 @@ def _test_body_with_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5709,14 +5709,14 @@ async def test_body_with_file_schema(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_file_schema
@@ -5755,7 +5755,7 @@ async def test_body_with_file_schema(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5776,14 +5776,14 @@ async def test_body_with_file_schema_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_file_schema
@@ -5822,7 +5822,7 @@ async def test_body_with_file_schema_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5843,14 +5843,14 @@ async def test_body_with_file_schema_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_file_schema
@@ -5889,7 +5889,7 @@ async def test_body_with_file_schema_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -5910,15 +5910,15 @@ def _test_body_with_file_schema_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5947,7 +5947,7 @@ def _test_body_with_file_schema_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5976,14 +5976,14 @@ async def test_body_with_query_params(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_query_params
@@ -6024,7 +6024,7 @@ async def test_body_with_query_params(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6046,14 +6046,14 @@ async def test_body_with_query_params_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_query_params
@@ -6094,7 +6094,7 @@ async def test_body_with_query_params_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6116,14 +6116,14 @@ async def test_body_with_query_params_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_query_params
@@ -6164,7 +6164,7 @@ async def test_body_with_query_params_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6186,15 +6186,15 @@ def _test_body_with_query_params_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6227,7 +6227,7 @@ def _test_body_with_query_params_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6255,14 +6255,14 @@ async def test_client_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test \"client\" model
@@ -6301,7 +6301,7 @@ async def test_client_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6322,14 +6322,14 @@ async def test_client_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test \"client\" model
@@ -6368,7 +6368,7 @@ async def test_client_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6389,14 +6389,14 @@ async def test_client_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test \"client\" model
@@ -6435,7 +6435,7 @@ async def test_client_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -6456,15 +6456,15 @@ def _test_client_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6500,7 +6500,7 @@ def _test_client_model_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6529,14 +6529,14 @@ async def test_date_time_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_date_time_query_parameter
@@ -6577,7 +6577,7 @@ async def test_date_time_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6599,14 +6599,14 @@ async def test_date_time_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_date_time_query_parameter
@@ -6647,7 +6647,7 @@ async def test_date_time_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6669,14 +6669,14 @@ async def test_date_time_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_date_time_query_parameter
@@ -6717,7 +6717,7 @@ async def test_date_time_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -6739,15 +6739,15 @@ def _test_date_time_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6778,7 +6778,7 @@ def _test_date_time_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6805,14 +6805,14 @@ async def test_empty_and_non_empty_responses(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test empty and non-empty responses
@@ -6848,7 +6848,7 @@ async def test_empty_and_non_empty_responses(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6869,14 +6869,14 @@ async def test_empty_and_non_empty_responses_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test empty and non-empty responses
@@ -6912,7 +6912,7 @@ async def test_empty_and_non_empty_responses_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6933,14 +6933,14 @@ async def test_empty_and_non_empty_responses_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test empty and non-empty responses
@@ -6976,7 +6976,7 @@ async def test_empty_and_non_empty_responses_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6997,15 +6997,15 @@ def _test_empty_and_non_empty_responses_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7026,7 +7026,7 @@ def _test_empty_and_non_empty_responses_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7059,7 +7059,7 @@ async def test_endpoint_parameters(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7068,14 +7068,14 @@ async def test_endpoint_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7156,7 +7156,7 @@ async def test_endpoint_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7183,7 +7183,7 @@ async def test_endpoint_parameters_with_http_info(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7192,14 +7192,14 @@ async def test_endpoint_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7280,7 +7280,7 @@ async def test_endpoint_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7307,7 +7307,7 @@ async def test_endpoint_parameters_without_preload_content(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7316,14 +7316,14 @@ async def test_endpoint_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7404,7 +7404,7 @@ async def test_endpoint_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7440,15 +7440,15 @@ def _test_endpoint_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7505,7 +7505,7 @@ def _test_endpoint_parameters_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_basic_test'
]
@@ -7533,14 +7533,14 @@ async def test_error_responses_with_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test error responses with model
@@ -7575,7 +7575,7 @@ async def test_error_responses_with_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7597,14 +7597,14 @@ async def test_error_responses_with_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test error responses with model
@@ -7639,7 +7639,7 @@ async def test_error_responses_with_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7661,14 +7661,14 @@ async def test_error_responses_with_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test error responses with model
@@ -7703,7 +7703,7 @@ async def test_error_responses_with_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7725,15 +7725,15 @@ def _test_error_responses_with_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7754,7 +7754,7 @@ def _test_error_responses_with_model_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7787,14 +7787,14 @@ async def test_group_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint to test group parameters (optional)
@@ -7848,7 +7848,7 @@ async def test_group_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -7874,14 +7874,14 @@ async def test_group_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint to test group parameters (optional)
@@ -7935,7 +7935,7 @@ async def test_group_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -7961,14 +7961,14 @@ async def test_group_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint to test group parameters (optional)
@@ -8022,7 +8022,7 @@ async def test_group_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = await self.api_client.call_api(
@@ -8048,15 +8048,15 @@ def _test_group_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8090,7 +8090,7 @@ def _test_group_parameters_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'bearer_test'
]
@@ -8115,18 +8115,18 @@ def _test_group_parameters_serialize(
@validate_call
async def test_inline_additional_properties(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline additionalProperties
@@ -8134,7 +8134,7 @@ async def test_inline_additional_properties(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8165,7 +8165,7 @@ async def test_inline_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8182,18 +8182,18 @@ async def test_inline_additional_properties(
@validate_call
async def test_inline_additional_properties_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline additionalProperties
@@ -8201,7 +8201,7 @@ async def test_inline_additional_properties_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8232,7 +8232,7 @@ async def test_inline_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8249,18 +8249,18 @@ async def test_inline_additional_properties_with_http_info(
@validate_call
async def test_inline_additional_properties_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline additionalProperties
@@ -8268,7 +8268,7 @@ async def test_inline_additional_properties_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8299,7 +8299,7 @@ async def test_inline_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8320,15 +8320,15 @@ def _test_inline_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8357,7 +8357,7 @@ def _test_inline_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8385,14 +8385,14 @@ async def test_inline_freeform_additional_properties(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline free-form additionalProperties
@@ -8431,7 +8431,7 @@ async def test_inline_freeform_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8452,14 +8452,14 @@ async def test_inline_freeform_additional_properties_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline free-form additionalProperties
@@ -8498,7 +8498,7 @@ async def test_inline_freeform_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8519,14 +8519,14 @@ async def test_inline_freeform_additional_properties_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline free-form additionalProperties
@@ -8565,7 +8565,7 @@ async def test_inline_freeform_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8586,15 +8586,15 @@ def _test_inline_freeform_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8623,7 +8623,7 @@ def _test_inline_freeform_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8652,14 +8652,14 @@ async def test_json_form_data(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test json serialization of form data
@@ -8701,7 +8701,7 @@ async def test_json_form_data(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8723,14 +8723,14 @@ async def test_json_form_data_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test json serialization of form data
@@ -8772,7 +8772,7 @@ async def test_json_form_data_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8794,14 +8794,14 @@ async def test_json_form_data_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test json serialization of form data
@@ -8843,7 +8843,7 @@ async def test_json_form_data_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8865,15 +8865,15 @@ def _test_json_form_data_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8904,7 +8904,7 @@ def _test_json_form_data_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8932,14 +8932,14 @@ async def test_object_for_multipart_requests(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_object_for_multipart_requests
@@ -8977,7 +8977,7 @@ async def test_object_for_multipart_requests(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -8998,14 +8998,14 @@ async def test_object_for_multipart_requests_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_object_for_multipart_requests
@@ -9043,7 +9043,7 @@ async def test_object_for_multipart_requests_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9064,14 +9064,14 @@ async def test_object_for_multipart_requests_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_object_for_multipart_requests
@@ -9109,7 +9109,7 @@ async def test_object_for_multipart_requests_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9130,15 +9130,15 @@ def _test_object_for_multipart_requests_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9167,7 +9167,7 @@ def _test_object_for_multipart_requests_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9191,24 +9191,24 @@ def _test_object_for_multipart_requests_serialize(
@validate_call
async def test_query_parameter_collection_format(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_query_parameter_collection_format
@@ -9216,19 +9216,19 @@ async def test_query_parameter_collection_format(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9265,7 +9265,7 @@ async def test_query_parameter_collection_format(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9282,24 +9282,24 @@ async def test_query_parameter_collection_format(
@validate_call
async def test_query_parameter_collection_format_with_http_info(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_query_parameter_collection_format
@@ -9307,19 +9307,19 @@ async def test_query_parameter_collection_format_with_http_info(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9356,7 +9356,7 @@ async def test_query_parameter_collection_format_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9373,24 +9373,24 @@ async def test_query_parameter_collection_format_with_http_info(
@validate_call
async def test_query_parameter_collection_format_without_preload_content(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_query_parameter_collection_format
@@ -9398,19 +9398,19 @@ async def test_query_parameter_collection_format_without_preload_content(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9447,7 +9447,7 @@ async def test_query_parameter_collection_format_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9474,7 +9474,7 @@ def _test_query_parameter_collection_format_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'pipe': 'pipes',
'ioutil': 'csv',
'http': 'ssv',
@@ -9482,12 +9482,12 @@ def _test_query_parameter_collection_format_serialize(
'context': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9529,7 +9529,7 @@ def _test_query_parameter_collection_format_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9553,18 +9553,18 @@ def _test_query_parameter_collection_format_serialize(
@validate_call
async def test_string_map_reference(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced string map
@@ -9572,7 +9572,7 @@ async def test_string_map_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9603,7 +9603,7 @@ async def test_string_map_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9620,18 +9620,18 @@ async def test_string_map_reference(
@validate_call
async def test_string_map_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced string map
@@ -9639,7 +9639,7 @@ async def test_string_map_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9670,7 +9670,7 @@ async def test_string_map_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9687,18 +9687,18 @@ async def test_string_map_reference_with_http_info(
@validate_call
async def test_string_map_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced string map
@@ -9706,7 +9706,7 @@ async def test_string_map_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9737,7 +9737,7 @@ async def test_string_map_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = await self.api_client.call_api(
@@ -9758,15 +9758,15 @@ def _test_string_map_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9795,7 +9795,7 @@ def _test_string_map_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9819,20 +9819,20 @@ def _test_string_map_reference_serialize(
@validate_call
async def upload_file_with_additional_properties(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads a file and additional properties using multipart/form-data
@@ -9877,7 +9877,7 @@ async def upload_file_with_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -9894,20 +9894,20 @@ async def upload_file_with_additional_properties(
@validate_call
async def upload_file_with_additional_properties_with_http_info(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads a file and additional properties using multipart/form-data
@@ -9952,7 +9952,7 @@ async def upload_file_with_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -9969,20 +9969,20 @@ async def upload_file_with_additional_properties_with_http_info(
@validate_call
async def upload_file_with_additional_properties_without_preload_content(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads a file and additional properties using multipart/form-data
@@ -10027,7 +10027,7 @@ async def upload_file_with_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -10050,15 +10050,15 @@ def _upload_file_with_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -10098,7 +10098,7 @@ def _upload_file_with_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_classname_tags123_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_classname_tags123_api.py
index 08cf85d488bb..e812b272776e 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_classname_tags123_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/fake_classname_tags123_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ async def test_classname(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test class name in snake case
@@ -90,7 +90,7 @@ async def test_classname(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -111,14 +111,14 @@ async def test_classname_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test class name in snake case
@@ -157,7 +157,7 @@ async def test_classname_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -178,14 +178,14 @@ async def test_classname_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test class name in snake case
@@ -224,7 +224,7 @@ async def test_classname_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = await self.api_client.call_api(
@@ -245,15 +245,15 @@ def _test_classname_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _test_classname_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key_query'
]
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/import_test_datetime_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/import_test_datetime_api.py
index 47876e858687..5f6dda97e29f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/import_test_datetime_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/import_test_datetime_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import datetime
@@ -41,14 +41,14 @@ async def import_test_return_datetime(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> datetime:
"""test date time
@@ -83,7 +83,7 @@ async def import_test_return_datetime(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -103,14 +103,14 @@ async def import_test_return_datetime_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[datetime]:
"""test date time
@@ -145,7 +145,7 @@ async def import_test_return_datetime_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -165,14 +165,14 @@ async def import_test_return_datetime_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test date time
@@ -207,7 +207,7 @@ async def import_test_return_datetime_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = await self.api_client.call_api(
@@ -227,15 +227,15 @@ def _import_test_return_datetime_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -256,7 +256,7 @@ def _import_test_return_datetime_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/pet_api.py
index 5da83f4a686a..3bd9d5df7515 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/pet_api.py
@@ -12,11 +12,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import List, Optional, Tuple, Union
+from typing import Optional, Union
from typing_extensions import Annotated
from petstore_api.models.model_api_response import ModelApiResponse
from petstore_api.models.pet import Pet
@@ -46,14 +46,14 @@ async def add_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Add a new pet to the store
@@ -92,7 +92,7 @@ async def add_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -114,14 +114,14 @@ async def add_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Add a new pet to the store
@@ -160,7 +160,7 @@ async def add_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -182,14 +182,14 @@ async def add_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Add a new pet to the store
@@ -228,7 +228,7 @@ async def add_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -250,15 +250,15 @@ def _add_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -288,7 +288,7 @@ def _add_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -319,14 +319,14 @@ async def delete_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Deletes a pet
@@ -368,7 +368,7 @@ async def delete_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -391,14 +391,14 @@ async def delete_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Deletes a pet
@@ -440,7 +440,7 @@ async def delete_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -463,14 +463,14 @@ async def delete_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Deletes a pet
@@ -512,7 +512,7 @@ async def delete_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -535,15 +535,15 @@ def _delete_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -561,7 +561,7 @@ def _delete_pet_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -586,26 +586,26 @@ def _delete_pet_serialize(
@validate_call
async def find_pets_by_status(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -636,8 +636,8 @@ async def find_pets_by_status(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -654,26 +654,26 @@ async def find_pets_by_status(
@validate_call
async def find_pets_by_status_with_http_info(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -704,8 +704,8 @@ async def find_pets_by_status_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -722,18 +722,18 @@ async def find_pets_by_status_with_http_info(
@validate_call
async def find_pets_by_status_without_preload_content(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Finds Pets by status
@@ -741,7 +741,7 @@ async def find_pets_by_status_without_preload_content(
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -772,8 +772,8 @@ async def find_pets_by_status_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -794,16 +794,16 @@ def _find_pets_by_status_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'status': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -829,7 +829,7 @@ def _find_pets_by_status_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -855,26 +855,26 @@ def _find_pets_by_status_serialize(
@validate_call
async def find_pets_by_tags(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -906,8 +906,8 @@ async def find_pets_by_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -924,26 +924,26 @@ async def find_pets_by_tags(
@validate_call
async def find_pets_by_tags_with_http_info(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -975,8 +975,8 @@ async def find_pets_by_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -993,18 +993,18 @@ async def find_pets_by_tags_with_http_info(
@validate_call
async def find_pets_by_tags_without_preload_content(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""(Deprecated) Finds Pets by tags
@@ -1012,7 +1012,7 @@ async def find_pets_by_tags_without_preload_content(
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1044,8 +1044,8 @@ async def find_pets_by_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = await self.api_client.call_api(
@@ -1066,16 +1066,16 @@ def _find_pets_by_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'tags': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1101,7 +1101,7 @@ def _find_pets_by_tags_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1131,14 +1131,14 @@ async def get_pet_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Find pet by ID
@@ -1177,7 +1177,7 @@ async def get_pet_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1200,14 +1200,14 @@ async def get_pet_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Find pet by ID
@@ -1246,7 +1246,7 @@ async def get_pet_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1269,14 +1269,14 @@ async def get_pet_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find pet by ID
@@ -1315,7 +1315,7 @@ async def get_pet_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1338,15 +1338,15 @@ def _get_pet_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1370,7 +1370,7 @@ def _get_pet_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -1399,14 +1399,14 @@ async def update_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Update an existing pet
@@ -1445,7 +1445,7 @@ async def update_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1469,14 +1469,14 @@ async def update_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Update an existing pet
@@ -1515,7 +1515,7 @@ async def update_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1539,14 +1539,14 @@ async def update_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Update an existing pet
@@ -1585,7 +1585,7 @@ async def update_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1609,15 +1609,15 @@ def _update_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1647,7 +1647,7 @@ def _update_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1679,14 +1679,14 @@ async def update_pet_with_form(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updates a pet in the store with form data
@@ -1731,7 +1731,7 @@ async def update_pet_with_form(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1755,14 +1755,14 @@ async def update_pet_with_form_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updates a pet in the store with form data
@@ -1807,7 +1807,7 @@ async def update_pet_with_form_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1831,14 +1831,14 @@ async def update_pet_with_form_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updates a pet in the store with form data
@@ -1883,7 +1883,7 @@ async def update_pet_with_form_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1907,15 +1907,15 @@ def _update_pet_with_form_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1948,7 +1948,7 @@ def _update_pet_with_form_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -1975,18 +1975,18 @@ async def upload_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image
@@ -2031,7 +2031,7 @@ async def upload_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2050,18 +2050,18 @@ async def upload_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image
@@ -2106,7 +2106,7 @@ async def upload_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2125,18 +2125,18 @@ async def upload_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image
@@ -2181,7 +2181,7 @@ async def upload_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2204,15 +2204,15 @@ def _upload_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2252,7 +2252,7 @@ def _upload_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -2278,19 +2278,19 @@ def _upload_file_serialize(
async def upload_file_with_required_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image (required)
@@ -2335,7 +2335,7 @@ async def upload_file_with_required_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2353,19 +2353,19 @@ async def upload_file_with_required_file(
async def upload_file_with_required_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image (required)
@@ -2410,7 +2410,7 @@ async def upload_file_with_required_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2428,19 +2428,19 @@ async def upload_file_with_required_file_with_http_info(
async def upload_file_with_required_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image (required)
@@ -2485,7 +2485,7 @@ async def upload_file_with_required_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = await self.api_client.call_api(
@@ -2508,15 +2508,15 @@ def _upload_file_with_required_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2556,7 +2556,7 @@ def _upload_file_with_required_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/store_api.py
index 79116ca74ca8..ec95444f06cb 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/store_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictInt, StrictStr
-from typing import Dict
from typing_extensions import Annotated
from petstore_api.models.order import Order
@@ -45,14 +44,14 @@ async def delete_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete purchase order by ID
@@ -91,7 +90,7 @@ async def delete_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -113,14 +112,14 @@ async def delete_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete purchase order by ID
@@ -159,7 +158,7 @@ async def delete_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -181,14 +180,14 @@ async def delete_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete purchase order by ID
@@ -227,7 +226,7 @@ async def delete_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -249,15 +248,15 @@ def _delete_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -273,7 +272,7 @@ def _delete_order_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -300,16 +299,16 @@ async def get_inventory(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> Dict[str, int]:
+ ) -> dict[str, int]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -343,8 +342,8 @@ async def get_inventory(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -363,16 +362,16 @@ async def get_inventory_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[Dict[str, int]]:
+ ) -> ApiResponse[dict[str, int]]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -406,8 +405,8 @@ async def get_inventory_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -426,14 +425,14 @@ async def get_inventory_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Returns pet inventories by status
@@ -469,8 +468,8 @@ async def get_inventory_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = await self.api_client.call_api(
*_param,
@@ -489,15 +488,15 @@ def _get_inventory_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -518,7 +517,7 @@ def _get_inventory_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -547,14 +546,14 @@ async def get_order_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Find purchase order by ID
@@ -593,7 +592,7 @@ async def get_order_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -616,14 +615,14 @@ async def get_order_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Find purchase order by ID
@@ -662,7 +661,7 @@ async def get_order_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -685,14 +684,14 @@ async def get_order_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find purchase order by ID
@@ -731,7 +730,7 @@ async def get_order_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -754,15 +753,15 @@ def _get_order_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -786,7 +785,7 @@ def _get_order_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -814,14 +813,14 @@ async def place_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Place an order for a pet
@@ -860,7 +859,7 @@ async def place_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -882,14 +881,14 @@ async def place_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Place an order for a pet
@@ -928,7 +927,7 @@ async def place_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -950,14 +949,14 @@ async def place_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Place an order for a pet
@@ -996,7 +995,7 @@ async def place_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -1018,15 +1017,15 @@ def _place_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1063,7 +1062,7 @@ def _place_order_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/user_api.py
index 9e4ff6771db8..4d7677c1b7c9 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api/user_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictStr
-from typing import List
from typing_extensions import Annotated
from petstore_api.models.user import User
@@ -45,14 +44,14 @@ async def create_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> None:
"""Create user
@@ -91,7 +90,7 @@ async def create_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -111,14 +110,14 @@ async def create_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> ApiResponse[None]:
"""Create user
@@ -157,7 +156,7 @@ async def create_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -177,14 +176,14 @@ async def create_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> RESTResponseType:
"""Create user
@@ -223,7 +222,7 @@ async def create_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -249,15 +248,15 @@ def _create_user_serialize(
]
_host = _hosts[_host_index]
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -286,7 +285,7 @@ def _create_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -310,18 +309,18 @@ def _create_user_serialize(
@validate_call
async def create_users_with_array_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -329,7 +328,7 @@ async def create_users_with_array_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -360,7 +359,7 @@ async def create_users_with_array_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -376,18 +375,18 @@ async def create_users_with_array_input(
@validate_call
async def create_users_with_array_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -395,7 +394,7 @@ async def create_users_with_array_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -426,7 +425,7 @@ async def create_users_with_array_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -442,18 +441,18 @@ async def create_users_with_array_input_with_http_info(
@validate_call
async def create_users_with_array_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -461,7 +460,7 @@ async def create_users_with_array_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -492,7 +491,7 @@ async def create_users_with_array_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -512,16 +511,16 @@ def _create_users_with_array_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -550,7 +549,7 @@ def _create_users_with_array_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,18 +573,18 @@ def _create_users_with_array_input_serialize(
@validate_call
async def create_users_with_list_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -593,7 +592,7 @@ async def create_users_with_list_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -624,7 +623,7 @@ async def create_users_with_list_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -640,18 +639,18 @@ async def create_users_with_list_input(
@validate_call
async def create_users_with_list_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -659,7 +658,7 @@ async def create_users_with_list_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -690,7 +689,7 @@ async def create_users_with_list_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -706,18 +705,18 @@ async def create_users_with_list_input_with_http_info(
@validate_call
async def create_users_with_list_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -725,7 +724,7 @@ async def create_users_with_list_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -756,7 +755,7 @@ async def create_users_with_list_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -776,16 +775,16 @@ def _create_users_with_list_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -814,7 +813,7 @@ def _create_users_with_list_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -842,14 +841,14 @@ async def delete_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete user
@@ -888,7 +887,7 @@ async def delete_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -910,14 +909,14 @@ async def delete_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete user
@@ -956,7 +955,7 @@ async def delete_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -978,14 +977,14 @@ async def delete_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete user
@@ -1024,7 +1023,7 @@ async def delete_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1046,15 +1045,15 @@ def _delete_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1070,7 +1069,7 @@ def _delete_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1098,14 +1097,14 @@ async def get_user_by_name(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> User:
"""Get user by user name
@@ -1144,7 +1143,7 @@ async def get_user_by_name(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1167,14 +1166,14 @@ async def get_user_by_name_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[User]:
"""Get user by user name
@@ -1213,7 +1212,7 @@ async def get_user_by_name_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1236,14 +1235,14 @@ async def get_user_by_name_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Get user by user name
@@ -1282,7 +1281,7 @@ async def get_user_by_name_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1305,15 +1304,15 @@ def _get_user_by_name_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1337,7 +1336,7 @@ def _get_user_by_name_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1366,14 +1365,14 @@ async def login_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Logs user into the system
@@ -1415,7 +1414,7 @@ async def login_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1438,14 +1437,14 @@ async def login_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Logs user into the system
@@ -1487,7 +1486,7 @@ async def login_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1510,14 +1509,14 @@ async def login_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs user into the system
@@ -1559,7 +1558,7 @@ async def login_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1582,15 +1581,15 @@ def _login_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1620,7 +1619,7 @@ def _login_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1647,14 +1646,14 @@ async def logout_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Logs out current logged in user session
@@ -1690,7 +1689,7 @@ async def logout_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1709,14 +1708,14 @@ async def logout_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Logs out current logged in user session
@@ -1752,7 +1751,7 @@ async def logout_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1771,14 +1770,14 @@ async def logout_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs out current logged in user session
@@ -1814,7 +1813,7 @@ async def logout_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = await self.api_client.call_api(
*_param,
@@ -1833,15 +1832,15 @@ def _logout_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1855,7 +1854,7 @@ def _logout_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1884,14 +1883,14 @@ async def update_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updated user
@@ -1933,7 +1932,7 @@ async def update_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1956,14 +1955,14 @@ async def update_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updated user
@@ -2005,7 +2004,7 @@ async def update_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2028,14 +2027,14 @@ async def update_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updated user
@@ -2077,7 +2076,7 @@ async def update_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2100,15 +2099,15 @@ def _update_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2139,7 +2138,7 @@ def _update_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/api_client.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/api_client.py
index 3d0170779a39..2f401cf5112f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/api_client.py
@@ -23,7 +23,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from petstore_api.configuration import Configuration
@@ -40,7 +40,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -289,7 +289,7 @@ async def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -437,16 +437,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -481,7 +481,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -511,7 +511,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -545,7 +545,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -578,7 +578,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/configuration.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/configuration.py
index 42ff1b555492..8c8201f2213d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/configuration.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/configuration.py
@@ -16,7 +16,7 @@
import logging
from logging import FileHandler
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
@@ -28,7 +28,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -125,13 +125,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -265,16 +265,16 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
signing_info: Optional[HttpSigningConfiguration]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[int] = None,
@@ -423,7 +423,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -666,7 +666,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -719,7 +719,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_any_type.py
index 19db20137bc4..8664dd11b01d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_any_type.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_class.py
index e4e4dbe21dea..000ed8b46d5c 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.pet import Pet
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,10 +28,10 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
""" # noqa: E501
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
- __properties: ClassVar[List[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
+ __properties: ClassVar[list[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_object.py
index d23fd87e51f3..2f1556c5e9ec 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_with_description_only.py
index b1f42400b676..f12bbeaec7f8 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/additional_properties_with_description_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_super_model.py
index 4793b8e4b3cd..560b3f978be5 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_super_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_super_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class AllOfSuperModel(BaseModel):
AllOfSuperModel
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- __properties: ClassVar[List[str]] = ["_name"]
+ __properties: ClassVar[list[str]] = ["_name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_with_single_ref.py
index 34e4c3dca7ea..265e904edc62 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_with_single_ref.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/all_of_with_single_ref.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.single_ref_type import SingleRefType
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class AllOfWithSingleRef(BaseModel):
""" # noqa: E501
username: Optional[StrictStr] = None
single_ref_type: Optional[SingleRefType] = Field(default=None, alias="SingleRefType")
- __properties: ClassVar[List[str]] = ["username", "SingleRefType"]
+ __properties: ClassVar[list[str]] = ["username", "SingleRefType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/animal.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/animal.py
index d2b83fbdb9d7..ac2ae713dd57 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/animal.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/animal.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class Animal(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: Optional[StrictStr] = 'red'
- __properties: ClassVar[List[str]] = ["className", "color"]
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class Animal(BaseModel):
__discriminator_property_name: ClassVar[str] = 'className'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Cat': 'Cat','Dog': 'Dog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[Cat, Dog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_color.py
index f6d277e79498..2039c0de8af9 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_color.py
@@ -18,30 +18,30 @@
import pprint
import re # noqa: F401
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import List, Optional
+from typing import Optional
from typing_extensions import Annotated
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- anyof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- anyof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Optional[Union[List[int], str]] = None
+ actual_instance: Optional[Union[list[int], str]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "List[int]", "str" }
+ any_of_schemas: set[str] = { "list[int]", "str" }
model_config = {
"validate_assignment": True,
@@ -62,13 +62,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.model_construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -82,12 +82,12 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -95,7 +95,7 @@ def from_json(cls, json_str: str) -> Self:
"""Returns the object represented by the json string"""
instance = cls.model_construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -104,7 +104,7 @@ def from_json(cls, json_str: str) -> Self:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -125,7 +125,7 @@ def from_json(cls, json_str: str) -> Self:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -139,7 +139,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_pig.py
index c949e136f415..0211d0291d94 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/any_of_pig.py
@@ -21,7 +21,7 @@
from typing import Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ any_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = {
"validate_assignment": True,
@@ -80,7 +80,7 @@ def actual_instance_must_validate_anyof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -117,7 +117,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_model.py
index ffdae49f239b..96fb714aa6a2 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ArrayOfArrayOfModel(BaseModel):
"""
ArrayOfArrayOfModel
""" # noqa: E501
- another_property: Optional[List[List[Tag]]] = None
- __properties: ClassVar[List[str]] = ["another_property"]
+ another_property: Optional[list[list[Tag]]] = None
+ __properties: ClassVar[list[str]] = ["another_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_number_only.py
index 3fb0fb5056f6..2440ba9502d9 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class ArrayOfArrayOfNumberOnly(BaseModel):
"""
ArrayOfArrayOfNumberOnly
""" # noqa: E501
- array_array_number: Optional[List[List[float]]] = Field(default=None, alias="ArrayArrayNumber")
- __properties: ClassVar[List[str]] = ["ArrayArrayNumber"]
+ array_array_number: Optional[list[list[float]]] = Field(default=None, alias="ArrayArrayNumber")
+ __properties: ClassVar[list[str]] = ["ArrayArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_map_model.py
index 3db556b3eb8a..c521f8806baf 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_map_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
""" # noqa: E501
- array_of_map_property: Optional[List[Dict[str, Tag]]] = None
- __properties: ClassVar[List[str]] = ["array_of_map_property"]
+ array_of_map_property: Optional[list[dict[str, Tag]]] = None
+ __properties: ClassVar[list[str]] = ["array_of_map_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_number_only.py
index 12b045326e11..aa33e549cea6 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class ArrayOfNumberOnly(BaseModel):
"""
ArrayOfNumberOnly
""" # noqa: E501
- array_number: Optional[List[float]] = Field(default=None, alias="ArrayNumber")
- __properties: ClassVar[List[str]] = ["ArrayNumber"]
+ array_number: Optional[list[float]] = Field(default=None, alias="ArrayNumber")
+ __properties: ClassVar[list[str]] = ["ArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_test.py
index b47021e9adb0..45cef2649e16 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/array_test.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.read_only_first import ReadOnlyFirst
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,11 +29,11 @@ class ArrayTest(BaseModel):
"""
ArrayTest
""" # noqa: E501
- array_of_string: Optional[Annotated[List[StrictStr], Field(min_length=0, max_length=3)]] = None
- array_of_nullable_float: Optional[List[Optional[float]]] = None
- array_array_of_integer: Optional[List[List[StrictInt]]] = None
- array_array_of_model: Optional[List[List[ReadOnlyFirst]]] = None
- __properties: ClassVar[List[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
+ array_of_string: Optional[Annotated[list[StrictStr], Field(min_length=0, max_length=3)]] = None
+ array_of_nullable_float: Optional[list[Optional[float]]] = None
+ array_array_of_integer: Optional[list[list[StrictInt]]] = None
+ array_array_of_model: Optional[list[list[ReadOnlyFirst]]] = None
+ __properties: ClassVar[list[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/base_discriminator.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/base_discriminator.py
index 3b8f10a664b0..39309c362424 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/base_discriminator.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/base_discriminator.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class BaseDiscriminator(BaseModel):
BaseDiscriminator
""" # noqa: E501
type_name: Optional[StrictStr] = Field(default=None, alias="_typeName")
- __properties: ClassVar[List[str]] = ["_typeName"]
+ __properties: ClassVar[list[str]] = ["_typeName"]
model_config = ConfigDict(
validate_by_name=True,
@@ -48,12 +48,12 @@ class BaseDiscriminator(BaseModel):
__discriminator_property_name: ClassVar[str] = '_typeName'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'string': 'PrimitiveString','Info': 'Info'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -95,7 +95,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/basque_pig.py
index 9282af3ff24f..40a546d8797d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/basque_pig.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/basque_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class BasquePig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: StrictStr
- __properties: ClassVar[List[str]] = ["className", "color"]
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of BasquePig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of BasquePig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/bathing.py
index 46b35c700e2b..050d625ca382 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/bathing.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/bathing.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Bathing(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bathing from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bathing from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/capitalization.py
index f4af4f06f207..5f8e58f797c5 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/capitalization.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/capitalization.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class Capitalization(BaseModel):
capital_snake: Optional[StrictStr] = Field(default=None, alias="Capital_Snake")
sca_eth_flow_points: Optional[StrictStr] = Field(default=None, alias="SCA_ETH_Flow_Points")
att_name: Optional[StrictStr] = Field(default=None, description="Name of the pet ", alias="ATT_NAME")
- __properties: ClassVar[List[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
+ __properties: ClassVar[list[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Capitalization from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Capitalization from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/cat.py
index 8692ceebb9a6..9b7b2adcb9e8 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/cat.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/cat.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Cat(Animal):
Cat
""" # noqa: E501
declawed: Optional[StrictBool] = None
- __properties: ClassVar[List[str]] = ["className", "color", "declawed"]
+ __properties: ClassVar[list[str]] = ["className", "color", "declawed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Cat from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Cat from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/category.py
index f7d60fe80c03..8853e6f7091f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/category.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/category.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: StrictStr
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_all_of_ref.py
index a7ea1daf778d..dbb656bf1c3b 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class CircularAllOfRef(BaseModel):
CircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- second_circular_all_of_ref: Optional[List[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
- __properties: ClassVar[List[str]] = ["_name", "secondCircularAllOfRef"]
+ second_circular_all_of_ref: Optional[list[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
+ __properties: ClassVar[list[str]] = ["_name", "secondCircularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_reference_model.py
index f43b0863da44..fdf20775b6fb 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_reference_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/circular_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class CircularReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[FirstRef] = None
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/class_model.py
index 331958d9b209..d960c1a8a095 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/class_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/class_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ClassModel(BaseModel):
Model for testing model with \"_class\" property
""" # noqa: E501
var_class: Optional[StrictStr] = Field(default=None, alias="_class")
- __properties: ClassVar[List[str]] = ["_class"]
+ __properties: ClassVar[list[str]] = ["_class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ClassModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ClassModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/client.py
index cdbddee56d31..c863b59bfae2 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/client.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/client.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Client(BaseModel):
Client
""" # noqa: E501
client: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["client"]
+ __properties: ClassVar[list[str]] = ["client"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Client from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Client from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/color.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/color.py
index bb740fb597d4..b3c3404d00f7 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/color.py
@@ -16,26 +16,26 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- oneof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- oneof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
- actual_instance: Optional[Union[List[int], str]] = None
- one_of_schemas: Set[str] = { "List[int]", "str" }
+ actual_instance: Optional[Union[list[int], str]] = None
+ one_of_schemas: set[str] = { "list[int]", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -61,13 +61,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.model_construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -81,15 +81,15 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -102,7 +102,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -111,7 +111,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -132,10 +132,10 @@ def from_json(cls, json_str: Optional[str]) -> Self:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -149,7 +149,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature.py
index e2af9fc33051..00fb74f97cc3 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature.py
@@ -19,9 +19,9 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
+from typing import Any, ClassVar, Union
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class Creature(BaseModel):
""" # noqa: E501
info: CreatureInfo
type: StrictStr
- __properties: ClassVar[List[str]] = ["info", "type"]
+ __properties: ClassVar[list[str]] = ["info", "type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class Creature(BaseModel):
__discriminator_property_name: ClassVar[str] = 'type'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Hunting__Dog': 'HuntingDog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -99,7 +99,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[HuntingDog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature_info.py
index 2488eca5d562..55f98c41bafd 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature_info.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/creature_info.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class CreatureInfo(BaseModel):
CreatureInfo
""" # noqa: E501
name: StrictStr
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CreatureInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CreatureInfo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/danish_pig.py
index ed51566a659e..d21daeee771a 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/danish_pig.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/danish_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class DanishPig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
size: StrictInt
- __properties: ClassVar[List[str]] = ["className", "size"]
+ __properties: ClassVar[list[str]] = ["className", "size"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DanishPig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DanishPig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/deprecated_object.py
index 0c09f54f0e91..970695f34904 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/deprecated_object.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/deprecated_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class DeprecatedObject(BaseModel):
DeprecatedObject
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_sub.py
index 987dae7f5c32..7589535b78c7 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_sub.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_sub.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from petstore_api.models.discriminator_all_of_super import DiscriminatorAllOfSuper
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class DiscriminatorAllOfSub(DiscriminatorAllOfSuper):
"""
DiscriminatorAllOfSub
""" # noqa: E501
- __properties: ClassVar[List[str]] = ["elementType"]
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_super.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_super.py
index 661015629f41..0ee5044289d5 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_super.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/discriminator_all_of_super.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,7 +33,7 @@ class DiscriminatorAllOfSuper(BaseModel):
DiscriminatorAllOfSuper
""" # noqa: E501
element_type: StrictStr = Field(alias="elementType")
- __properties: ClassVar[List[str]] = ["elementType"]
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -47,12 +47,12 @@ class DiscriminatorAllOfSuper(BaseModel):
__discriminator_property_name: ClassVar[str] = 'elementType'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'DiscriminatorAllOfSub': 'DiscriminatorAllOfSub'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -73,7 +73,7 @@ def from_json(cls, json_str: str) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dog.py
index b8752a1f948f..e224d25a2f2d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dog.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dog.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Dog(Animal):
Dog
""" # noqa: E501
breed: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["className", "color", "breed"]
+ __properties: ClassVar[list[str]] = ["className", "color", "breed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Dog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Dog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dummy_model.py
index 19a8109a056d..0eb1efad96a3 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dummy_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/dummy_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class DummyModel(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SelfReferenceModel] = None
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DummyModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DummyModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_arrays.py
index d841ea10e5b8..674013ea3853 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_arrays.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class EnumArrays(BaseModel):
EnumArrays
""" # noqa: E501
just_symbol: Optional[StrictStr] = None
- array_enum: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["just_symbol", "array_enum"]
+ array_enum: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["just_symbol", "array_enum"]
@field_validator('just_symbol')
def just_symbol_validate_enum(cls, value):
@@ -73,7 +73,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_ref_with_default_value.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_ref_with_default_value.py
index 5c29c04aa7f2..34a7c741f695 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_ref_with_default_value.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_ref_with_default_value.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.data_output_format import DataOutputFormat
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class EnumRefWithDefaultValue(BaseModel):
EnumRefWithDefaultValue
""" # noqa: E501
report_format: Optional[DataOutputFormat] = DataOutputFormat.JSON
- __properties: ClassVar[List[str]] = ["report_format"]
+ __properties: ClassVar[list[str]] = ["report_format"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_test.py
index 604194529754..a30cc7f681e5 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_test.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/enum_test.py
@@ -18,14 +18,14 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.enum_number_vendor_ext import EnumNumberVendorExt
from petstore_api.models.enum_string_vendor_ext import EnumStringVendorExt
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_default_value import OuterEnumDefaultValue
from petstore_api.models.outer_enum_integer import OuterEnumInteger
from petstore_api.models.outer_enum_integer_default_value import OuterEnumIntegerDefaultValue
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -46,7 +46,7 @@ class EnumTest(BaseModel):
outer_enum_integer_default_value: Optional[OuterEnumIntegerDefaultValue] = Field(default=OuterEnumIntegerDefaultValue.NUMBER_0, alias="outerEnumIntegerDefaultValue")
enum_number_vendor_ext: Optional[EnumNumberVendorExt] = Field(default=None, alias="enumNumberVendorExt")
enum_string_vendor_ext: Optional[EnumStringVendorExt] = Field(default=None, alias="enumStringVendorExt")
- __properties: ClassVar[List[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
+ __properties: ClassVar[list[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
@field_validator('enum_string')
def enum_string_validate_enum(cls, value):
@@ -136,7 +136,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -146,7 +146,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -162,7 +162,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/feeding.py
index ce5a36f49afb..05071d38a190 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/feeding.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/feeding.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class Feeding(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Feeding from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Feeding from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file.py
index 7d8d010f8c82..0c3669e1b3ae 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class File(BaseModel):
Must be named `File` for test.
""" # noqa: E501
source_uri: Optional[StrictStr] = Field(default=None, description="Test capitalization", alias="sourceURI")
- __properties: ClassVar[List[str]] = ["sourceURI"]
+ __properties: ClassVar[list[str]] = ["sourceURI"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of File from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of File from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file_schema_test_class.py
index 4c04c79dad7d..f22d55c60d88 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/file_schema_test_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FileSchemaTestClass(BaseModel):
FileSchemaTestClass
""" # noqa: E501
file: Optional[File] = None
- files: Optional[List[File]] = None
- __properties: ClassVar[List[str]] = ["file", "files"]
+ files: Optional[list[File]] = None
+ __properties: ClassVar[list[str]] = ["file", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/first_ref.py
index 5c03477f15f0..e30d4a9fd320 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/first_ref.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/first_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class FirstRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SecondRef] = None
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FirstRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FirstRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo.py
index 65a289e187de..187c197b8103 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Foo(BaseModel):
Foo
""" # noqa: E501
bar: Optional[StrictStr] = 'bar'
- __properties: ClassVar[List[str]] = ["bar"]
+ __properties: ClassVar[list[str]] = ["bar"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Foo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Foo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo_get_default_response.py
index e3a3f7a66aed..17e69ffc3f3c 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo_get_default_response.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/foo_get_default_response.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.foo import Foo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class FooGetDefaultResponse(BaseModel):
FooGetDefaultResponse
""" # noqa: E501
string: Optional[Foo] = None
- __properties: ClassVar[List[str]] = ["string"]
+ __properties: ClassVar[list[str]] = ["string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/format_test.py
index c1314e23cbcf..b0599910e888 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/format_test.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/format_test.py
@@ -20,10 +20,10 @@
from datetime import date, datetime
from decimal import Decimal
from pydantic import BaseModel, ConfigDict, Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional, Tuple, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -41,14 +41,14 @@ class FormatTest(BaseModel):
string: Optional[Annotated[str, Field(strict=True)]] = None
string_with_double_quote_pattern: Optional[Annotated[str, Field(strict=True)]] = None
byte: Optional[Union[StrictBytes, StrictStr]] = None
- binary: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None
+ binary: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None
var_date: date = Field(alias="date")
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
uuid: Optional[UUID] = None
password: Annotated[str, Field(min_length=10, strict=True, max_length=64)]
pattern_with_digits: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string that is a 10 digit number. Can have leading zeros.")
pattern_with_digits_and_delimiter: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.")
- __properties: ClassVar[List[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
+ __properties: ClassVar[list[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
@field_validator('string')
def string_validate_regular_expression(cls, value):
@@ -123,7 +123,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FormatTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -133,7 +133,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -144,7 +144,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FormatTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/has_only_read_only.py
index c7a1c9f0913e..bce64615e695 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/has_only_read_only.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/has_only_read_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class HasOnlyReadOnly(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
foo: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["bar", "foo"]
+ __properties: ClassVar[list[str]] = ["bar", "foo"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"foo",
])
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/health_check_result.py
index 270725757bad..8991a4da5ab8 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/health_check_result.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/health_check_result.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class HealthCheckResult(BaseModel):
Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model.
""" # noqa: E501
nullable_message: Optional[StrictStr] = Field(default=None, alias="NullableMessage")
- __properties: ClassVar[List[str]] = ["NullableMessage"]
+ __properties: ClassVar[list[str]] = ["NullableMessage"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/hunting_dog.py
index 4064ce67183c..5663af9615c0 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/hunting_dog.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/hunting_dog.py
@@ -18,10 +18,10 @@
import json
from pydantic import ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature import Creature
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class HuntingDog(Creature):
HuntingDog
""" # noqa: E501
is_trained: Optional[StrictBool] = Field(default=None, alias="isTrained")
- __properties: ClassVar[List[str]] = ["info", "type", "isTrained"]
+ __properties: ClassVar[list[str]] = ["info", "type", "isTrained"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HuntingDog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HuntingDog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/info.py
index 0f57b71af2aa..7ceff30f0e7a 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/info.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/info.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Info(BaseDiscriminator):
Info
""" # noqa: E501
val: Optional[BaseDiscriminator] = None
- __properties: ClassVar[List[str]] = ["_typeName", "val"]
+ __properties: ClassVar[list[str]] = ["_typeName", "val"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Info from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Info from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/inner_dict_with_property.py
index 9b709fb15e43..a46bfbaac69f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/inner_dict_with_property.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
""" # noqa: E501
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
- __properties: ClassVar[List[str]] = ["aProperty"]
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
+ __properties: ClassVar[list[str]] = ["aProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/input_all_of.py
index 2dd24cc67053..dd4d0f80a339 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/input_all_of.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class InputAllOf(BaseModel):
"""
InputAllOf
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InputAllOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InputAllOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/int_or_string.py
index f2a5a0a2d4a3..02180a2d6a53 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/int_or_string.py
@@ -16,10 +16,10 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -33,7 +33,7 @@ class IntOrString(BaseModel):
# data type: str
oneof_schema_2_validator: Optional[StrictStr] = None
actual_instance: Optional[Union[int, str]] = None
- one_of_schemas: Set[str] = { "int", "str" }
+ one_of_schemas: set[str] = { "int", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -78,7 +78,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -126,7 +126,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], int, str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], int, str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/list_class.py
index 634b8d012d29..9a3397cadb19 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/list_class.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/list_class.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ListClass(BaseModel):
ListClass
""" # noqa: E501
var_123_list: Optional[StrictStr] = Field(default=None, alias="123-list")
- __properties: ClassVar[List[str]] = ["123-list"]
+ __properties: ClassVar[list[str]] = ["123-list"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ListClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ListClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_of_array_of_model.py
index 8f8d882c67b3..ba6d3fa9a51f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
""" # noqa: E501
- shop_id_to_org_online_lip_map: Optional[Dict[str, List[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
- __properties: ClassVar[List[str]] = ["shopIdToOrgOnlineLipMap"]
+ shop_id_to_org_online_lip_map: Optional[dict[str, list[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ __properties: ClassVar[list[str]] = ["shopIdToOrgOnlineLipMap"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_test.py
index ac4080efbc88..c1e7e7a2a2f7 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/map_test.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,11 +27,11 @@ class MapTest(BaseModel):
"""
MapTest
""" # noqa: E501
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
- __properties: ClassVar[List[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
+ __properties: ClassVar[list[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@field_validator('map_of_enum_string')
def map_of_enum_string_validate_enum(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/mixed_properties_and_additional_properties_class.py
index f1ef7f55ead3..cb5739a124a0 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -19,10 +19,10 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,8 +32,8 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
""" # noqa: E501
uuid: Optional[UUID] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
- __properties: ClassVar[List[str]] = ["uuid", "dateTime", "map"]
+ map: Optional[dict[str, Animal]] = None
+ __properties: ClassVar[list[str]] = ["uuid", "dateTime", "map"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model200_response.py
index 63c9faad21f5..cedb1a55999e 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model200_response.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model200_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Model200Response(BaseModel):
""" # noqa: E501
name: Optional[StrictInt] = None
var_class: Optional[StrictStr] = Field(default=None, alias="class")
- __properties: ClassVar[List[str]] = ["name", "class"]
+ __properties: ClassVar[list[str]] = ["name", "class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Model200Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Model200Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_api_response.py
index 517441e5d545..172793ac34a9 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_api_response.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_api_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class ModelApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["code", "type", "message"]
+ __properties: ClassVar[list[str]] = ["code", "type", "message"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_field.py
index 80951622bed4..52b053f77bd2 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_field.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_field.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ModelField(BaseModel):
ModelField
""" # noqa: E501
var_field: Optional[StrictStr] = Field(default=None, alias="field")
- __properties: ClassVar[List[str]] = ["field"]
+ __properties: ClassVar[list[str]] = ["field"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelField from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelField from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_return.py
index 374b0b454781..10a15359c859 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_return.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/model_return.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ModelReturn(BaseModel):
Model for testing reserved words
""" # noqa: E501
var_return: Optional[StrictInt] = Field(default=None, alias="return")
- __properties: ClassVar[List[str]] = ["return"]
+ __properties: ClassVar[list[str]] = ["return"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelReturn from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelReturn from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/multi_arrays.py
index 0a3e337a950f..8f2c1c9647c0 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/multi_arrays.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,9 +29,9 @@ class MultiArrays(BaseModel):
"""
MultiArrays
""" # noqa: E501
- tags: Optional[List[Tag]] = None
- files: Optional[List[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
- __properties: ClassVar[List[str]] = ["tags", "files"]
+ tags: Optional[list[Tag]] = None
+ files: Optional[list[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
+ __properties: ClassVar[list[str]] = ["tags", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MultiArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -89,7 +89,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MultiArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/name.py
index 9b4f7a436ed6..7752ffa4d016 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/name.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class Name(BaseModel):
snake_case: Optional[StrictInt] = None
var_property: Optional[StrictStr] = Field(default=None, alias="property")
var_123_number: Optional[StrictInt] = Field(default=None, alias="123Number")
- __properties: ClassVar[List[str]] = ["name", "snake_case", "property", "123Number"]
+ __properties: ClassVar[list[str]] = ["name", "snake_case", "property", "123Number"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Name from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"snake_case",
"var_123_number",
])
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Name from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_class.py
index 25c6ba3d4d39..453cf7cc96e4 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_class.py
@@ -19,8 +19,8 @@
from datetime import date, datetime
from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,14 +35,14 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[List[Dict[str, Any]]] = None
- array_and_items_nullable_prop: Optional[List[Optional[Dict[str, Any]]]] = None
- array_items_nullable: Optional[List[Optional[Dict[str, Any]]]] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- object_items_nullable: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
+ array_nullable_prop: Optional[list[dict[str, Any]]] = None
+ array_and_items_nullable_prop: Optional[list[Optional[dict[str, Any]]]] = None
+ array_items_nullable: Optional[list[Optional[dict[str, Any]]]] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ object_items_nullable: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
model_config = ConfigDict(
validate_by_name=True,
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_property.py
index f396a5f10045..d111fa5d0809 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_property.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/nullable_property.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class NullableProperty(BaseModel):
""" # noqa: E501
id: StrictInt
name: Optional[Annotated[str, Field(strict=True)]]
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
@field_validator('name')
def name_validate_regular_expression(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/number_only.py
index b91b8d045003..39ebe490e2a3 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/number_only.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class NumberOnly(BaseModel):
NumberOnly
""" # noqa: E501
just_number: Optional[float] = Field(default=None, alias="JustNumber")
- __properties: ClassVar[List[str]] = ["JustNumber"]
+ __properties: ClassVar[list[str]] = ["JustNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_to_test_additional_properties.py
index 2ac8a9d37a2c..ef52cbbec779 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_to_test_additional_properties.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_to_test_additional_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class ObjectToTestAdditionalProperties(BaseModel):
Minimal object
""" # noqa: E501
var_property: Optional[StrictBool] = Field(default=False, description="Property", alias="property")
- __properties: ClassVar[List[str]] = ["property"]
+ __properties: ClassVar[list[str]] = ["property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_with_deprecated_fields.py
index e3bae640cdb7..1a65ab0a2c2c 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/object_with_deprecated_fields.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.deprecated_object import DeprecatedObject
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class ObjectWithDeprecatedFields(BaseModel):
uuid: Optional[StrictStr] = None
id: Optional[float] = None
deprecated_ref: Optional[DeprecatedObject] = Field(default=None, alias="deprecatedRef")
- bars: Optional[List[StrictStr]] = None
- __properties: ClassVar[List[str]] = ["uuid", "id", "deprecatedRef", "bars"]
+ bars: Optional[list[StrictStr]] = None
+ __properties: ClassVar[list[str]] = ["uuid", "id", "deprecatedRef", "bars"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/order.py
index 0cd26ab72b34..5669dbddac50 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/order.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/order.py
@@ -19,8 +19,8 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- __properties: ClassVar[List[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
+ __properties: ClassVar[list[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Order from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Order from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_composite.py
index 05186f8015e6..196dc5d62837 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_composite.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_composite.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class OuterComposite(BaseModel):
my_number: Optional[float] = None
my_string: Optional[StrictStr] = None
my_boolean: Optional[StrictBool] = None
- __properties: ClassVar[List[str]] = ["my_number", "my_string", "my_boolean"]
+ __properties: ClassVar[list[str]] = ["my_number", "my_string", "my_boolean"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterComposite from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterComposite from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_object_with_enum_property.py
index b73faea2c909..8a6e80dcbd7c 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_object_with_enum_property.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/outer_object_with_enum_property.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_integer import OuterEnumInteger
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class OuterObjectWithEnumProperty(BaseModel):
""" # noqa: E501
str_value: Optional[OuterEnum] = None
value: OuterEnumInteger
- __properties: ClassVar[List[str]] = ["str_value", "value"]
+ __properties: ClassVar[list[str]] = ["str_value", "value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent.py
index b8a5de498efe..f66cfd2450a3 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Parent(BaseModel):
"""
Parent
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Parent from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Parent from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent_with_optional_dict.py
index 5193e6750c1f..85eba221c11f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/parent_with_optional_dict.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pet.py
index 4543f973c33d..3735eccc8041 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pet.py
@@ -18,11 +18,11 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,10 +33,10 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
category: Optional[Category] = None
name: StrictStr
- photo_urls: Annotated[List[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: Annotated[list[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- __properties: ClassVar[List[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
+ __properties: ClassVar[list[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -69,7 +69,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pig.py
index b3a759e89b7b..84990e6d521b 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pig.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -34,7 +34,7 @@ class Pig(BaseModel):
# data type: DanishPig
oneof_schema_2_validator: Optional[DanishPig] = None
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
- one_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ one_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = ConfigDict(
validate_assignment=True,
@@ -42,7 +42,7 @@ class Pig(BaseModel):
)
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
}
def __init__(self, *args, **kwargs) -> None:
@@ -80,7 +80,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -122,7 +122,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pony_sizes.py
index c70683def48d..60bab06703a0 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pony_sizes.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/pony_sizes.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.type import Type
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class PonySizes(BaseModel):
PonySizes
""" # noqa: E501
type: Optional[Type] = None
- __properties: ClassVar[List[str]] = ["type"]
+ __properties: ClassVar[list[str]] = ["type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PonySizes from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PonySizes from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/poop_cleaning.py
index 3733c7bd9b00..83e3dd925c39 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/poop_cleaning.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/poop_cleaning.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class PoopCleaning(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PoopCleaning from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PoopCleaning from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/primitive_string.py
index f23b8503d855..aa5a70e798ee 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/primitive_string.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/primitive_string.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class PrimitiveString(BaseDiscriminator):
PrimitiveString
""" # noqa: E501
value: Optional[StrictStr] = Field(default=None, alias="_value")
- __properties: ClassVar[List[str]] = ["_typeName", "_value"]
+ __properties: ClassVar[list[str]] = ["_typeName", "_value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PrimitiveString from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PrimitiveString from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_map.py
index d48ade5d9984..d07c9fa2b197 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_map.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class PropertyMap(BaseModel):
"""
PropertyMap
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyMap from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyMap from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_name_collision.py
index edae9c5f2c1d..83341f6717ff 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_name_collision.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/property_name_collision.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,7 +30,7 @@ class PropertyNameCollision(BaseModel):
underscore_type: Optional[StrictStr] = Field(default=None, alias="_type")
type: Optional[StrictStr] = None
type_with_underscore: Optional[StrictStr] = Field(default=None, alias="type_")
- __properties: ClassVar[List[str]] = ["_type", "type", "type_"]
+ __properties: ClassVar[list[str]] = ["_type", "type", "type_"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/read_only_first.py
index e22fac10b2b5..3b646e20bc56 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/read_only_first.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/read_only_first.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class ReadOnlyFirst(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
baz: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["bar", "baz"]
+ __properties: ClassVar[list[str]] = ["bar", "baz"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* OpenAPI `readOnly` fields are excluded.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
])
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_circular_all_of_ref.py
index b56e8782933e..3de9334565ef 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class SecondCircularAllOfRef(BaseModel):
SecondCircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- circular_all_of_ref: Optional[List[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
- __properties: ClassVar[List[str]] = ["_name", "circularAllOfRef"]
+ circular_all_of_ref: Optional[list[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
+ __properties: ClassVar[list[str]] = ["_name", "circularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_ref.py
index 69eb99fad636..38c5746c117d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_ref.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/second_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class SecondRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
circular_ref: Optional[CircularReferenceModel] = None
- __properties: ClassVar[List[str]] = ["category", "circular_ref"]
+ __properties: ClassVar[list[str]] = ["category", "circular_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/self_reference_model.py
index fb84a0573dba..565cd5555100 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/self_reference_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/self_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class SelfReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[DummyModel] = None
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_model_name.py
index 4188827e69e7..c3686f934651 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_model_name.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_model_name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class SpecialModelName(BaseModel):
SpecialModelName
""" # noqa: E501
special_property_name: Optional[StrictInt] = Field(default=None, alias="$special[property.name]")
- __properties: ClassVar[List[str]] = ["$special[property.name]"]
+ __properties: ClassVar[list[str]] = ["$special[property.name]"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialModelName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialModelName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_name.py
index 432acdbdb90a..21ca42a8859f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_name.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/special_name.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.category import Category
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class SpecialName(BaseModel):
var_property: Optional[StrictInt] = Field(default=None, alias="property")
var_async: Optional[Category] = Field(default=None, alias="async")
var_schema: Optional[StrictStr] = Field(default=None, description="pet status in the store", alias="schema")
- __properties: ClassVar[List[str]] = ["property", "async", "schema"]
+ __properties: ClassVar[list[str]] = ["property", "async", "schema"]
@field_validator('var_schema')
def var_schema_validate_enum(cls, value):
@@ -64,7 +64,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -74,7 +74,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tag.py
index 5dbba0015e8b..48feecf53518 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tag.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tag.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -73,7 +73,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task.py
index e926f4c275d5..a987c90a464d 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from uuid import UUID
from petstore_api.models.task_activity import TaskActivity
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,7 +31,7 @@ class Task(BaseModel):
""" # noqa: E501
id: UUID
activity: TaskActivity
- __properties: ClassVar[List[str]] = ["id", "activity"]
+ __properties: ClassVar[list[str]] = ["id", "activity"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Task from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -78,7 +78,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Task from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task_activity.py
index cc1e1fc5a60f..51bec8a6c3f0 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/task_activity.py
@@ -16,12 +16,12 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -37,7 +37,7 @@ class TaskActivity(BaseModel):
# data type: Bathing
oneof_schema_3_validator: Optional[Bathing] = None
actual_instance: Optional[Union[Bathing, Feeding, PoopCleaning]] = None
- one_of_schemas: Set[str] = { "Bathing", "Feeding", "PoopCleaning" }
+ one_of_schemas: set[str] = { "Bathing", "Feeding", "PoopCleaning" }
model_config = ConfigDict(
validate_assignment=True,
@@ -85,7 +85,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -133,7 +133,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], Bathing, Feeding, PoopCleaning]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], Bathing, Feeding, PoopCleaning]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model400_response.py
index 6f4bba183ee4..2a4287ffe603 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model400_response.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model400_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestErrorResponsesWithModel400Response(BaseModel):
TestErrorResponsesWithModel400Response
""" # noqa: E501
reason400: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["reason400"]
+ __properties: ClassVar[list[str]] = ["reason400"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model404_response.py
index 16b242b56b71..3d6b01a887d4 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model404_response.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_error_responses_with_model404_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestErrorResponsesWithModel404Response(BaseModel):
TestErrorResponsesWithModel404Response
""" # noqa: E501
reason404: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["reason404"]
+ __properties: ClassVar[list[str]] = ["reason404"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 67f893c75448..2ba526ab52ba 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
""" # noqa: E501
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["someProperty"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["someProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_model_with_enum_default.py
index 65d891895df5..08c8cf85ae14 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_model_with_enum_default.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_model_with_enum_default.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.test_enum import TestEnum
from petstore_api.models.test_enum_with_default import TestEnumWithDefault
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,7 +34,7 @@ class TestModelWithEnumDefault(BaseModel):
test_enum_with_default: Optional[TestEnumWithDefault] = TestEnumWithDefault.ZWEI
test_string_with_default: Optional[StrictStr] = 'ahoy matey'
test_inline_defined_enum_with_default: Optional[StrictStr] = 'B'
- __properties: ClassVar[List[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
+ __properties: ClassVar[list[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
@field_validator('test_inline_defined_enum_with_default')
def test_inline_defined_enum_with_default_validate_enum(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_object_for_multipart_requests_request_marker.py
index e1b5959f69d1..fcb8b131f86f 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_object_for_multipart_requests_request_marker.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/test_object_for_multipart_requests_request_marker.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class TestObjectForMultipartRequestsRequestMarker(BaseModel):
TestObjectForMultipartRequestsRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tiger.py
index c1f7eebcb138..bb3f2bc18bff 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tiger.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/tiger.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class Tiger(BaseModel):
Tiger
""" # noqa: E501
skill: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["skill"]
+ __properties: ClassVar[list[str]] = ["skill"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tiger from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tiger from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index 4c79fe8bc7e5..2ab6e7027639 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[CreatureInfo]]] = Field(default=None, alias="dictProperty")
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[CreatureInfo]]] = Field(default=None, alias="dictProperty")
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -62,7 +62,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index 78d19e89e0e7..3e77e43d2972 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,8 +27,8 @@ class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[StrictStr]]] = Field(default=None, alias="dictProperty")
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[StrictStr]]] = Field(default=None, alias="dictProperty")
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/upload_file_with_additional_properties_request_object.py
index 02ccb0a8c689..4105e790cab7 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/upload_file_with_additional_properties_request_object.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/upload_file_with_additional_properties_request_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,7 +28,7 @@ class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
Additional object
""" # noqa: E501
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["name"]
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -51,7 +51,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -61,7 +61,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -72,7 +72,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/user.py
index 624e5c2135c4..99e4ddb8e98e 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/user.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/user.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,7 +35,7 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, description="User Status", alias="userStatus")
- __properties: ClassVar[List[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
+ __properties: ClassVar[list[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
model_config = ConfigDict(
validate_by_name=True,
@@ -58,7 +58,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of User from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of User from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/uuid_with_pattern.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/uuid_with_pattern.py
index 9936e04769f1..8bb2d8099be8 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/uuid_with_pattern.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/uuid_with_pattern.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,7 +29,7 @@ class UuidWithPattern(BaseModel):
UuidWithPattern
""" # noqa: E501
id: Optional[UUID] = None
- __properties: ClassVar[List[str]] = ["id"]
+ __properties: ClassVar[list[str]] = ["id"]
@field_validator('id')
def id_validate_regular_expression(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/with_nested_one_of.py
index 4f2003d80cc3..95a89ced47f5 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/models/with_nested_one_of.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/models/with_nested_one_of.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.one_of_enum_string import OneOfEnumString
from petstore_api.models.pig import Pig
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,7 +32,7 @@ class WithNestedOneOf(BaseModel):
size: Optional[StrictInt] = None
nested_pig: Optional[Pig] = None
nested_oneof_enum_string: Optional[OneOfEnumString] = None
- __properties: ClassVar[List[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
+ __properties: ClassVar[list[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
were set at model initialization. Other fields with value `None`
are ignored.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
])
_dict = self.model_dump(
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-httpx/petstore_api/signing.py b/samples/openapi3/client/petstore/python-httpx/petstore_api/signing.py
index e0ef058f4677..c52fe689fc96 100644
--- a/samples/openapi3/client/petstore/python-httpx/petstore_api/signing.py
+++ b/samples/openapi3/client/petstore/python-httpx/petstore_api/signing.py
@@ -22,7 +22,7 @@
import os
import re
from time import time
-from typing import List, Optional, Union
+from typing import Optional, Union
from urllib.parse import urlencode, urlparse
# The constants below define a subset of HTTP headers that can be included in the
@@ -128,7 +128,7 @@ def __init__(self,
signing_scheme: str,
private_key_path: str,
private_key_passphrase: Union[None, str]=None,
- signed_headers: Optional[List[str]]=None,
+ signed_headers: Optional[list[str]]=None,
signing_algorithm: Optional[str]=None,
hash_algorithm: Optional[str]=None,
signature_max_validity: Optional[timedelta]=None,
diff --git a/samples/openapi3/client/petstore/python-httpx/tests/test_model.py b/samples/openapi3/client/petstore/python-httpx/tests/test_model.py
index 0ef8d9956a78..3a527b5139df 100644
--- a/samples/openapi3/client/petstore/python-httpx/tests/test_model.py
+++ b/samples/openapi3/client/petstore/python-httpx/tests/test_model.py
@@ -190,7 +190,7 @@ def test_list(self):
self.assertTrue(False) # this line shouldn't execute
except ValueError as e:
#error_message = (
- # "1 validation error for List\n"
+ # "1 validation error for list\n"
# "123-list\n"
# " str type expected (type=type_error.str)\n")
self.assertTrue("str type expected" in str(e))
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-lazyImports/docs/AdditionalPropertiesClass.md
index 5128004d8f9a..faa22e6e6b1b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/AdditionalPropertiesClass.md
@@ -5,9 +5,9 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfModel.md
index f866863d53f9..13c6bc20804d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfNumberOnly.md
index 32bd2dfbf1e2..8fa0d5954ad1 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfMapModel.md
index fd39f86fce5e..44ee01bb37b6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfMapModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfNumberOnly.md
index b814d7594942..bc690d09040a 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayTest.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayTest.md
index ed871fae662d..014e64472c22 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ArrayTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[Optional[float]]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[Optional[float]]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python-lazyImports/docs/CircularAllOfRef.md
index 65b171177e58..d39dfe136b9f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/CircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/EnumArrays.md b/samples/openapi3/client/petstore/python-lazyImports/docs/EnumArrays.md
index f44617497bce..687172987bc6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/EnumArrays.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/FakeApi.md b/samples/openapi3/client/petstore/python-lazyImports/docs/FakeApi.md
index 7ef2af8af2c3..6e42c2b8ddaa 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/FakeApi.md
@@ -651,7 +651,7 @@ with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -669,7 +669,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1121,7 +1121,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1163,7 +1163,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1393,7 +1393,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1409,7 +1409,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2093,7 +2093,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2109,7 +2109,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2350,13 +2350,13 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2371,13 +2371,13 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2426,7 +2426,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2442,7 +2442,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python-lazyImports/docs/FileSchemaTestClass.md
index e1118042a8ec..aae04a5bbba7 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/FileSchemaTestClass.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/InputAllOf.md b/samples/openapi3/client/petstore/python-lazyImports/docs/InputAllOf.md
index 45298f5308fc..adc4f9cdcb63 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/InputAllOf.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python-lazyImports/docs/MapOfArrayOfModel.md
index 71a4ef66b682..d2a7c41b46f9 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/MapOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/MapTest.md b/samples/openapi3/client/petstore/python-lazyImports/docs/MapTest.md
index d04b82e9378c..33032142168b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/MapTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-lazyImports/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 84134317aefc..7e5fb0b3071d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **UUID** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/MultiArrays.md b/samples/openapi3/client/petstore/python-lazyImports/docs/MultiArrays.md
index fea5139e7e73..62398cd42693 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/MultiArrays.md
@@ -5,8 +5,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/NullableClass.md b/samples/openapi3/client/petstore/python-lazyImports/docs/NullableClass.md
index 0387dcc2c67a..1378ee707136 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/NullableClass.md
@@ -12,12 +12,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[Optional[object]]** | | [optional]
-**array_items_nullable** | **List[Optional[object]]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, Optional[object]]** | | [optional]
-**object_items_nullable** | **Dict[str, Optional[object]]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[Optional[object]]** | | [optional]
+**array_items_nullable** | **list[Optional[object]]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, Optional[object]]** | | [optional]
+**object_items_nullable** | **dict[str, Optional[object]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ObjectWithDeprecatedFields.md
index 6dbd2ace04f1..fcdff0bdf060 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ObjectWithDeprecatedFields.md
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/Parent.md b/samples/openapi3/client/petstore/python-lazyImports/docs/Parent.md
index 7387f9250aad..56fbac8cbb28 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/Parent.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python-lazyImports/docs/ParentWithOptionalDict.md
index bfc8688ea26f..7d278755c08f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/ParentWithOptionalDict.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/Pet.md b/samples/openapi3/client/petstore/python-lazyImports/docs/Pet.md
index 5329cf2fb925..14d1e224a08a 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/PetApi.md b/samples/openapi3/client/petstore/python-lazyImports/docs/PetApi.md
index 3396f1974f91..02e33e420dfc 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/PetApi.md
@@ -228,7 +228,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -324,7 +324,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -342,11 +342,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -367,7 +367,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -463,7 +463,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -481,11 +481,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/PropertyMap.md b/samples/openapi3/client/petstore/python-lazyImports/docs/PropertyMap.md
index a55a0e5c6f01..0c32115e8200 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/PropertyMap.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python-lazyImports/docs/SecondCircularAllOfRef.md
index 65ebdd4c7e1d..894564db2594 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/SecondCircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/StoreApi.md b/samples/openapi3/client/petstore/python-lazyImports/docs/StoreApi.md
index 19d6a89e5b9f..c719b75f2c84 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/StoreApi.md
@@ -77,7 +77,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -131,7 +131,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalModelListProperties.md
index 68cd00ab0a7a..dbf6ee475056 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalStringListProperties.md
index 045b0e22ad09..f9bf8d7b3489 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-lazyImports/docs/UserApi.md b/samples/openapi3/client/petstore/python-lazyImports/docs/UserApi.md
index a1e152924c0c..63cdc66d93c4 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python-lazyImports/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -123,7 +123,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -173,7 +173,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -189,7 +189,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/another_fake_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/another_fake_api.py
index 56f2ab2cd1cd..b6ff53d1b760 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/another_fake_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/another_fake_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ def call_123_test_special_tags(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test special tags
@@ -90,7 +90,7 @@ def call_123_test_special_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -111,14 +111,14 @@ def call_123_test_special_tags_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test special tags
@@ -157,7 +157,7 @@ def call_123_test_special_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -178,14 +178,14 @@ def call_123_test_special_tags_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test special tags
@@ -224,7 +224,7 @@ def call_123_test_special_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -245,15 +245,15 @@ def _call_123_test_special_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _call_123_test_special_tags_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/default_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/default_api.py
index 2d007b2f26d3..32341443fd5c 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/default_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/default_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from petstore_api.models.foo_get_default_response import FooGetDefaultResponse
@@ -41,14 +41,14 @@ def foo_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> FooGetDefaultResponse:
"""foo_get
@@ -83,7 +83,7 @@ def foo_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -102,14 +102,14 @@ def foo_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[FooGetDefaultResponse]:
"""foo_get
@@ -144,7 +144,7 @@ def foo_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -163,14 +163,14 @@ def foo_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""foo_get
@@ -205,7 +205,7 @@ def foo_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -224,15 +224,15 @@ def _foo_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -253,7 +253,7 @@ def _foo_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_api.py
index 2373d1680c58..facaae5234fb 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_api.py
@@ -12,12 +12,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import Field, StrictBool, StrictBytes, StrictFloat, StrictInt, StrictStr, field_validator
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
from petstore_api.models.client import Client
@@ -56,18 +56,18 @@ def __init__(self, api_client=None) -> None:
@validate_call
def fake_any_type_request_body(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test any type request body
@@ -105,7 +105,7 @@ def fake_any_type_request_body(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -122,18 +122,18 @@ def fake_any_type_request_body(
@validate_call
def fake_any_type_request_body_with_http_info(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test any type request body
@@ -171,7 +171,7 @@ def fake_any_type_request_body_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -188,18 +188,18 @@ def fake_any_type_request_body_with_http_info(
@validate_call
def fake_any_type_request_body_without_preload_content(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test any type request body
@@ -237,7 +237,7 @@ def fake_any_type_request_body_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -258,15 +258,15 @@ def _fake_any_type_request_body_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -295,7 +295,7 @@ def _fake_any_type_request_body_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -323,14 +323,14 @@ def fake_enum_ref_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test enum reference query parameter
@@ -368,7 +368,7 @@ def fake_enum_ref_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -389,14 +389,14 @@ def fake_enum_ref_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test enum reference query parameter
@@ -434,7 +434,7 @@ def fake_enum_ref_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -455,14 +455,14 @@ def fake_enum_ref_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum reference query parameter
@@ -500,7 +500,7 @@ def fake_enum_ref_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -521,15 +521,15 @@ def _fake_enum_ref_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -547,7 +547,7 @@ def _fake_enum_ref_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,14 +574,14 @@ def fake_health_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> HealthCheckResult:
"""Health check endpoint
@@ -616,7 +616,7 @@ def fake_health_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -636,14 +636,14 @@ def fake_health_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[HealthCheckResult]:
"""Health check endpoint
@@ -678,7 +678,7 @@ def fake_health_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -698,14 +698,14 @@ def fake_health_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Health check endpoint
@@ -740,7 +740,7 @@ def fake_health_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -760,15 +760,15 @@ def _fake_health_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -789,7 +789,7 @@ def _fake_health_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -819,14 +819,14 @@ def fake_http_signature_test(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test http signature authentication
@@ -870,7 +870,7 @@ def fake_http_signature_test(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -893,14 +893,14 @@ def fake_http_signature_test_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test http signature authentication
@@ -944,7 +944,7 @@ def fake_http_signature_test_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -967,14 +967,14 @@ def fake_http_signature_test_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test http signature authentication
@@ -1018,7 +1018,7 @@ def fake_http_signature_test_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -1041,15 +1041,15 @@ def _fake_http_signature_test_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1085,7 +1085,7 @@ def _fake_http_signature_test_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_signature_test'
]
@@ -1114,14 +1114,14 @@ def fake_outer_boolean_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""fake_outer_boolean_serialize
@@ -1160,7 +1160,7 @@ def fake_outer_boolean_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1181,14 +1181,14 @@ def fake_outer_boolean_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""fake_outer_boolean_serialize
@@ -1227,7 +1227,7 @@ def fake_outer_boolean_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1248,14 +1248,14 @@ def fake_outer_boolean_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_boolean_serialize
@@ -1294,7 +1294,7 @@ def fake_outer_boolean_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1315,15 +1315,15 @@ def _fake_outer_boolean_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1359,7 +1359,7 @@ def _fake_outer_boolean_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1387,14 +1387,14 @@ def fake_outer_composite_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterComposite:
"""fake_outer_composite_serialize
@@ -1433,7 +1433,7 @@ def fake_outer_composite_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1454,14 +1454,14 @@ def fake_outer_composite_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterComposite]:
"""fake_outer_composite_serialize
@@ -1500,7 +1500,7 @@ def fake_outer_composite_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1521,14 +1521,14 @@ def fake_outer_composite_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_composite_serialize
@@ -1567,7 +1567,7 @@ def fake_outer_composite_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1588,15 +1588,15 @@ def _fake_outer_composite_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1632,7 +1632,7 @@ def _fake_outer_composite_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1660,14 +1660,14 @@ def fake_outer_number_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""fake_outer_number_serialize
@@ -1706,7 +1706,7 @@ def fake_outer_number_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1727,14 +1727,14 @@ def fake_outer_number_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""fake_outer_number_serialize
@@ -1773,7 +1773,7 @@ def fake_outer_number_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1794,14 +1794,14 @@ def fake_outer_number_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_number_serialize
@@ -1840,7 +1840,7 @@ def fake_outer_number_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1861,15 +1861,15 @@ def _fake_outer_number_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1905,7 +1905,7 @@ def _fake_outer_number_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1933,14 +1933,14 @@ def fake_outer_string_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""fake_outer_string_serialize
@@ -1979,7 +1979,7 @@ def fake_outer_string_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2000,14 +2000,14 @@ def fake_outer_string_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""fake_outer_string_serialize
@@ -2046,7 +2046,7 @@ def fake_outer_string_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2067,14 +2067,14 @@ def fake_outer_string_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_string_serialize
@@ -2113,7 +2113,7 @@ def fake_outer_string_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2134,15 +2134,15 @@ def _fake_outer_string_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2178,7 +2178,7 @@ def _fake_outer_string_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2203,18 +2203,18 @@ def _fake_outer_string_serialize_serialize(
def fake_property_enum_integer_serialize(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterObjectWithEnumProperty:
"""fake_property_enum_integer_serialize
@@ -2224,7 +2224,7 @@ def fake_property_enum_integer_serialize(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2256,7 +2256,7 @@ def fake_property_enum_integer_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2274,18 +2274,18 @@ def fake_property_enum_integer_serialize(
def fake_property_enum_integer_serialize_with_http_info(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterObjectWithEnumProperty]:
"""fake_property_enum_integer_serialize
@@ -2295,7 +2295,7 @@ def fake_property_enum_integer_serialize_with_http_info(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2327,7 +2327,7 @@ def fake_property_enum_integer_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2345,18 +2345,18 @@ def fake_property_enum_integer_serialize_with_http_info(
def fake_property_enum_integer_serialize_without_preload_content(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_property_enum_integer_serialize
@@ -2366,7 +2366,7 @@ def fake_property_enum_integer_serialize_without_preload_content(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2398,7 +2398,7 @@ def fake_property_enum_integer_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2420,16 +2420,16 @@ def _fake_property_enum_integer_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'param': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2469,7 +2469,7 @@ def _fake_property_enum_integer_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2496,14 +2496,14 @@ def fake_ref_enum_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> EnumClass:
"""test ref to enum string
@@ -2538,7 +2538,7 @@ def fake_ref_enum_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2558,14 +2558,14 @@ def fake_ref_enum_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[EnumClass]:
"""test ref to enum string
@@ -2600,7 +2600,7 @@ def fake_ref_enum_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2620,14 +2620,14 @@ def fake_ref_enum_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test ref to enum string
@@ -2662,7 +2662,7 @@ def fake_ref_enum_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2682,15 +2682,15 @@ def _fake_ref_enum_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2711,7 +2711,7 @@ def _fake_ref_enum_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2738,14 +2738,14 @@ def fake_return_boolean(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""test returning boolean
@@ -2780,7 +2780,7 @@ def fake_return_boolean(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2800,14 +2800,14 @@ def fake_return_boolean_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""test returning boolean
@@ -2842,7 +2842,7 @@ def fake_return_boolean_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2862,14 +2862,14 @@ def fake_return_boolean_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning boolean
@@ -2904,7 +2904,7 @@ def fake_return_boolean_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2924,15 +2924,15 @@ def _fake_return_boolean_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2953,7 +2953,7 @@ def _fake_return_boolean_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2980,14 +2980,14 @@ def fake_return_byte_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""test byte like json
@@ -3022,7 +3022,7 @@ def fake_return_byte_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3042,14 +3042,14 @@ def fake_return_byte_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""test byte like json
@@ -3084,7 +3084,7 @@ def fake_return_byte_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3104,14 +3104,14 @@ def fake_return_byte_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test byte like json
@@ -3146,7 +3146,7 @@ def fake_return_byte_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3166,15 +3166,15 @@ def _fake_return_byte_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3195,7 +3195,7 @@ def _fake_return_byte_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3222,14 +3222,14 @@ def fake_return_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning enum
@@ -3264,7 +3264,7 @@ def fake_return_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3284,14 +3284,14 @@ def fake_return_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning enum
@@ -3326,7 +3326,7 @@ def fake_return_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3346,14 +3346,14 @@ def fake_return_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning enum
@@ -3388,7 +3388,7 @@ def fake_return_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3408,15 +3408,15 @@ def _fake_return_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3437,7 +3437,7 @@ def _fake_return_enum_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3464,14 +3464,14 @@ def fake_return_enum_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test enum like json
@@ -3506,7 +3506,7 @@ def fake_return_enum_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3526,14 +3526,14 @@ def fake_return_enum_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test enum like json
@@ -3568,7 +3568,7 @@ def fake_return_enum_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3588,14 +3588,14 @@ def fake_return_enum_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum like json
@@ -3630,7 +3630,7 @@ def fake_return_enum_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3650,15 +3650,15 @@ def _fake_return_enum_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3679,7 +3679,7 @@ def _fake_return_enum_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3706,14 +3706,14 @@ def fake_return_float(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""test returning float
@@ -3748,7 +3748,7 @@ def fake_return_float(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3768,14 +3768,14 @@ def fake_return_float_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""test returning float
@@ -3810,7 +3810,7 @@ def fake_return_float_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3830,14 +3830,14 @@ def fake_return_float_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning float
@@ -3872,7 +3872,7 @@ def fake_return_float_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3892,15 +3892,15 @@ def _fake_return_float_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3921,7 +3921,7 @@ def _fake_return_float_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3948,14 +3948,14 @@ def fake_return_int(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> int:
"""test returning int
@@ -3990,7 +3990,7 @@ def fake_return_int(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4010,14 +4010,14 @@ def fake_return_int_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[int]:
"""test returning int
@@ -4052,7 +4052,7 @@ def fake_return_int_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4072,14 +4072,14 @@ def fake_return_int_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning int
@@ -4114,7 +4114,7 @@ def fake_return_int_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4134,15 +4134,15 @@ def _fake_return_int_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4163,7 +4163,7 @@ def _fake_return_int_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4190,16 +4190,16 @@ def fake_return_list_of_objects(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[List[Tag]]:
+ ) -> list[list[Tag]]:
"""test returning list of objects
@@ -4232,8 +4232,8 @@ def fake_return_list_of_objects(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4252,16 +4252,16 @@ def fake_return_list_of_objects_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[List[Tag]]]:
+ ) -> ApiResponse[list[list[Tag]]]:
"""test returning list of objects
@@ -4294,8 +4294,8 @@ def fake_return_list_of_objects_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4314,14 +4314,14 @@ def fake_return_list_of_objects_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning list of objects
@@ -4356,8 +4356,8 @@ def fake_return_list_of_objects_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4376,15 +4376,15 @@ def _fake_return_list_of_objects_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4405,7 +4405,7 @@ def _fake_return_list_of_objects_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4432,14 +4432,14 @@ def fake_return_str_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test str like json
@@ -4474,7 +4474,7 @@ def fake_return_str_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4494,14 +4494,14 @@ def fake_return_str_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test str like json
@@ -4536,7 +4536,7 @@ def fake_return_str_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4556,14 +4556,14 @@ def fake_return_str_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test str like json
@@ -4598,7 +4598,7 @@ def fake_return_str_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4618,15 +4618,15 @@ def _fake_return_str_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4647,7 +4647,7 @@ def _fake_return_str_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4674,14 +4674,14 @@ def fake_return_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning string
@@ -4716,7 +4716,7 @@ def fake_return_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4736,14 +4736,14 @@ def fake_return_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning string
@@ -4778,7 +4778,7 @@ def fake_return_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4798,14 +4798,14 @@ def fake_return_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning string
@@ -4840,7 +4840,7 @@ def fake_return_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4860,15 +4860,15 @@ def _fake_return_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4889,7 +4889,7 @@ def _fake_return_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4917,14 +4917,14 @@ def fake_uuid_example(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test uuid example
@@ -4962,7 +4962,7 @@ def fake_uuid_example(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -4983,14 +4983,14 @@ def fake_uuid_example_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test uuid example
@@ -5028,7 +5028,7 @@ def fake_uuid_example_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5049,14 +5049,14 @@ def fake_uuid_example_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test uuid example
@@ -5094,7 +5094,7 @@ def fake_uuid_example_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5115,15 +5115,15 @@ def _fake_uuid_example_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5141,7 +5141,7 @@ def _fake_uuid_example_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5165,18 +5165,18 @@ def _fake_uuid_example_serialize(
@validate_call
def test_additional_properties_reference(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced additionalProperties
@@ -5184,7 +5184,7 @@ def test_additional_properties_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5215,7 +5215,7 @@ def test_additional_properties_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5232,18 +5232,18 @@ def test_additional_properties_reference(
@validate_call
def test_additional_properties_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced additionalProperties
@@ -5251,7 +5251,7 @@ def test_additional_properties_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5282,7 +5282,7 @@ def test_additional_properties_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5299,18 +5299,18 @@ def test_additional_properties_reference_with_http_info(
@validate_call
def test_additional_properties_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced additionalProperties
@@ -5318,7 +5318,7 @@ def test_additional_properties_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5349,7 +5349,7 @@ def test_additional_properties_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5370,15 +5370,15 @@ def _test_additional_properties_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5407,7 +5407,7 @@ def _test_additional_properties_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5431,18 +5431,18 @@ def _test_additional_properties_reference_serialize(
@validate_call
def test_body_with_binary(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_binary
@@ -5481,7 +5481,7 @@ def test_body_with_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5498,18 +5498,18 @@ def test_body_with_binary(
@validate_call
def test_body_with_binary_with_http_info(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_binary
@@ -5548,7 +5548,7 @@ def test_body_with_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5565,18 +5565,18 @@ def test_body_with_binary_with_http_info(
@validate_call
def test_body_with_binary_without_preload_content(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_binary
@@ -5615,7 +5615,7 @@ def test_body_with_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5636,15 +5636,15 @@ def _test_body_with_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5681,7 +5681,7 @@ def _test_body_with_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5709,14 +5709,14 @@ def test_body_with_file_schema(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_file_schema
@@ -5755,7 +5755,7 @@ def test_body_with_file_schema(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5776,14 +5776,14 @@ def test_body_with_file_schema_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_file_schema
@@ -5822,7 +5822,7 @@ def test_body_with_file_schema_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5843,14 +5843,14 @@ def test_body_with_file_schema_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_file_schema
@@ -5889,7 +5889,7 @@ def test_body_with_file_schema_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5910,15 +5910,15 @@ def _test_body_with_file_schema_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5947,7 +5947,7 @@ def _test_body_with_file_schema_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5976,14 +5976,14 @@ def test_body_with_query_params(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_query_params
@@ -6024,7 +6024,7 @@ def test_body_with_query_params(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6046,14 +6046,14 @@ def test_body_with_query_params_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_query_params
@@ -6094,7 +6094,7 @@ def test_body_with_query_params_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6116,14 +6116,14 @@ def test_body_with_query_params_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_query_params
@@ -6164,7 +6164,7 @@ def test_body_with_query_params_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6186,15 +6186,15 @@ def _test_body_with_query_params_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6227,7 +6227,7 @@ def _test_body_with_query_params_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6255,14 +6255,14 @@ def test_client_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test \"client\" model
@@ -6301,7 +6301,7 @@ def test_client_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6322,14 +6322,14 @@ def test_client_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test \"client\" model
@@ -6368,7 +6368,7 @@ def test_client_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6389,14 +6389,14 @@ def test_client_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test \"client\" model
@@ -6435,7 +6435,7 @@ def test_client_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6456,15 +6456,15 @@ def _test_client_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6500,7 +6500,7 @@ def _test_client_model_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6529,14 +6529,14 @@ def test_date_time_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_date_time_query_parameter
@@ -6577,7 +6577,7 @@ def test_date_time_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6599,14 +6599,14 @@ def test_date_time_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_date_time_query_parameter
@@ -6647,7 +6647,7 @@ def test_date_time_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6669,14 +6669,14 @@ def test_date_time_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_date_time_query_parameter
@@ -6717,7 +6717,7 @@ def test_date_time_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6739,15 +6739,15 @@ def _test_date_time_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6778,7 +6778,7 @@ def _test_date_time_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6805,14 +6805,14 @@ def test_empty_and_non_empty_responses(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test empty and non-empty responses
@@ -6848,7 +6848,7 @@ def test_empty_and_non_empty_responses(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6869,14 +6869,14 @@ def test_empty_and_non_empty_responses_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test empty and non-empty responses
@@ -6912,7 +6912,7 @@ def test_empty_and_non_empty_responses_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6933,14 +6933,14 @@ def test_empty_and_non_empty_responses_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test empty and non-empty responses
@@ -6976,7 +6976,7 @@ def test_empty_and_non_empty_responses_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6997,15 +6997,15 @@ def _test_empty_and_non_empty_responses_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7026,7 +7026,7 @@ def _test_empty_and_non_empty_responses_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7059,7 +7059,7 @@ def test_endpoint_parameters(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7068,14 +7068,14 @@ def test_endpoint_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7156,7 +7156,7 @@ def test_endpoint_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7183,7 +7183,7 @@ def test_endpoint_parameters_with_http_info(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7192,14 +7192,14 @@ def test_endpoint_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7280,7 +7280,7 @@ def test_endpoint_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7307,7 +7307,7 @@ def test_endpoint_parameters_without_preload_content(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7316,14 +7316,14 @@ def test_endpoint_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7404,7 +7404,7 @@ def test_endpoint_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7440,15 +7440,15 @@ def _test_endpoint_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7505,7 +7505,7 @@ def _test_endpoint_parameters_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_basic_test'
]
@@ -7533,14 +7533,14 @@ def test_error_responses_with_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test error responses with model
@@ -7575,7 +7575,7 @@ def test_error_responses_with_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7597,14 +7597,14 @@ def test_error_responses_with_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test error responses with model
@@ -7639,7 +7639,7 @@ def test_error_responses_with_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7661,14 +7661,14 @@ def test_error_responses_with_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test error responses with model
@@ -7703,7 +7703,7 @@ def test_error_responses_with_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7725,15 +7725,15 @@ def _test_error_responses_with_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7754,7 +7754,7 @@ def _test_error_responses_with_model_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7787,14 +7787,14 @@ def test_group_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint to test group parameters (optional)
@@ -7848,7 +7848,7 @@ def test_group_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -7874,14 +7874,14 @@ def test_group_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint to test group parameters (optional)
@@ -7935,7 +7935,7 @@ def test_group_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -7961,14 +7961,14 @@ def test_group_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint to test group parameters (optional)
@@ -8022,7 +8022,7 @@ def test_group_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -8048,15 +8048,15 @@ def _test_group_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8090,7 +8090,7 @@ def _test_group_parameters_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'bearer_test'
]
@@ -8115,18 +8115,18 @@ def _test_group_parameters_serialize(
@validate_call
def test_inline_additional_properties(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline additionalProperties
@@ -8134,7 +8134,7 @@ def test_inline_additional_properties(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8165,7 +8165,7 @@ def test_inline_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8182,18 +8182,18 @@ def test_inline_additional_properties(
@validate_call
def test_inline_additional_properties_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline additionalProperties
@@ -8201,7 +8201,7 @@ def test_inline_additional_properties_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8232,7 +8232,7 @@ def test_inline_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8249,18 +8249,18 @@ def test_inline_additional_properties_with_http_info(
@validate_call
def test_inline_additional_properties_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline additionalProperties
@@ -8268,7 +8268,7 @@ def test_inline_additional_properties_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8299,7 +8299,7 @@ def test_inline_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8320,15 +8320,15 @@ def _test_inline_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8357,7 +8357,7 @@ def _test_inline_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8385,14 +8385,14 @@ def test_inline_freeform_additional_properties(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline free-form additionalProperties
@@ -8431,7 +8431,7 @@ def test_inline_freeform_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8452,14 +8452,14 @@ def test_inline_freeform_additional_properties_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline free-form additionalProperties
@@ -8498,7 +8498,7 @@ def test_inline_freeform_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8519,14 +8519,14 @@ def test_inline_freeform_additional_properties_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline free-form additionalProperties
@@ -8565,7 +8565,7 @@ def test_inline_freeform_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8586,15 +8586,15 @@ def _test_inline_freeform_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8623,7 +8623,7 @@ def _test_inline_freeform_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8652,14 +8652,14 @@ def test_json_form_data(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test json serialization of form data
@@ -8701,7 +8701,7 @@ def test_json_form_data(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8723,14 +8723,14 @@ def test_json_form_data_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test json serialization of form data
@@ -8772,7 +8772,7 @@ def test_json_form_data_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8794,14 +8794,14 @@ def test_json_form_data_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test json serialization of form data
@@ -8843,7 +8843,7 @@ def test_json_form_data_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8865,15 +8865,15 @@ def _test_json_form_data_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8904,7 +8904,7 @@ def _test_json_form_data_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8932,14 +8932,14 @@ def test_object_for_multipart_requests(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_object_for_multipart_requests
@@ -8977,7 +8977,7 @@ def test_object_for_multipart_requests(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8998,14 +8998,14 @@ def test_object_for_multipart_requests_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_object_for_multipart_requests
@@ -9043,7 +9043,7 @@ def test_object_for_multipart_requests_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9064,14 +9064,14 @@ def test_object_for_multipart_requests_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_object_for_multipart_requests
@@ -9109,7 +9109,7 @@ def test_object_for_multipart_requests_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9130,15 +9130,15 @@ def _test_object_for_multipart_requests_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9167,7 +9167,7 @@ def _test_object_for_multipart_requests_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9191,24 +9191,24 @@ def _test_object_for_multipart_requests_serialize(
@validate_call
def test_query_parameter_collection_format(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_query_parameter_collection_format
@@ -9216,19 +9216,19 @@ def test_query_parameter_collection_format(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9265,7 +9265,7 @@ def test_query_parameter_collection_format(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9282,24 +9282,24 @@ def test_query_parameter_collection_format(
@validate_call
def test_query_parameter_collection_format_with_http_info(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_query_parameter_collection_format
@@ -9307,19 +9307,19 @@ def test_query_parameter_collection_format_with_http_info(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9356,7 +9356,7 @@ def test_query_parameter_collection_format_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9373,24 +9373,24 @@ def test_query_parameter_collection_format_with_http_info(
@validate_call
def test_query_parameter_collection_format_without_preload_content(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_query_parameter_collection_format
@@ -9398,19 +9398,19 @@ def test_query_parameter_collection_format_without_preload_content(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9447,7 +9447,7 @@ def test_query_parameter_collection_format_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9474,7 +9474,7 @@ def _test_query_parameter_collection_format_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'pipe': 'pipes',
'ioutil': 'csv',
'http': 'ssv',
@@ -9482,12 +9482,12 @@ def _test_query_parameter_collection_format_serialize(
'context': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9529,7 +9529,7 @@ def _test_query_parameter_collection_format_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9553,18 +9553,18 @@ def _test_query_parameter_collection_format_serialize(
@validate_call
def test_string_map_reference(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced string map
@@ -9572,7 +9572,7 @@ def test_string_map_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9603,7 +9603,7 @@ def test_string_map_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9620,18 +9620,18 @@ def test_string_map_reference(
@validate_call
def test_string_map_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced string map
@@ -9639,7 +9639,7 @@ def test_string_map_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9670,7 +9670,7 @@ def test_string_map_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9687,18 +9687,18 @@ def test_string_map_reference_with_http_info(
@validate_call
def test_string_map_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced string map
@@ -9706,7 +9706,7 @@ def test_string_map_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9737,7 +9737,7 @@ def test_string_map_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9758,15 +9758,15 @@ def _test_string_map_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9795,7 +9795,7 @@ def _test_string_map_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9819,20 +9819,20 @@ def _test_string_map_reference_serialize(
@validate_call
def upload_file_with_additional_properties(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads a file and additional properties using multipart/form-data
@@ -9877,7 +9877,7 @@ def upload_file_with_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -9894,20 +9894,20 @@ def upload_file_with_additional_properties(
@validate_call
def upload_file_with_additional_properties_with_http_info(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads a file and additional properties using multipart/form-data
@@ -9952,7 +9952,7 @@ def upload_file_with_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -9969,20 +9969,20 @@ def upload_file_with_additional_properties_with_http_info(
@validate_call
def upload_file_with_additional_properties_without_preload_content(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads a file and additional properties using multipart/form-data
@@ -10027,7 +10027,7 @@ def upload_file_with_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -10050,15 +10050,15 @@ def _upload_file_with_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -10098,7 +10098,7 @@ def _upload_file_with_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_classname_tags123_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_classname_tags123_api.py
index e373462e5f5b..1aa861478c09 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_classname_tags123_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/fake_classname_tags123_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ def test_classname(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test class name in snake case
@@ -90,7 +90,7 @@ def test_classname(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -111,14 +111,14 @@ def test_classname_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test class name in snake case
@@ -157,7 +157,7 @@ def test_classname_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -178,14 +178,14 @@ def test_classname_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test class name in snake case
@@ -224,7 +224,7 @@ def test_classname_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -245,15 +245,15 @@ def _test_classname_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _test_classname_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key_query'
]
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/import_test_datetime_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/import_test_datetime_api.py
index ae01fa137fa1..25dcb6578520 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/import_test_datetime_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/import_test_datetime_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import datetime
@@ -41,14 +41,14 @@ def import_test_return_datetime(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> datetime:
"""test date time
@@ -83,7 +83,7 @@ def import_test_return_datetime(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -103,14 +103,14 @@ def import_test_return_datetime_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[datetime]:
"""test date time
@@ -145,7 +145,7 @@ def import_test_return_datetime_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -165,14 +165,14 @@ def import_test_return_datetime_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test date time
@@ -207,7 +207,7 @@ def import_test_return_datetime_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -227,15 +227,15 @@ def _import_test_return_datetime_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -256,7 +256,7 @@ def _import_test_return_datetime_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/pet_api.py
index 7d4cf604eb15..3e24a847941f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/pet_api.py
@@ -12,11 +12,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import List, Optional, Tuple, Union
+from typing import Optional, Union
from typing_extensions import Annotated
from petstore_api.models.model_api_response import ModelApiResponse
from petstore_api.models.pet import Pet
@@ -46,14 +46,14 @@ def add_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Add a new pet to the store
@@ -92,7 +92,7 @@ def add_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -114,14 +114,14 @@ def add_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Add a new pet to the store
@@ -160,7 +160,7 @@ def add_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -182,14 +182,14 @@ def add_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Add a new pet to the store
@@ -228,7 +228,7 @@ def add_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -250,15 +250,15 @@ def _add_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -288,7 +288,7 @@ def _add_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -319,14 +319,14 @@ def delete_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Deletes a pet
@@ -368,7 +368,7 @@ def delete_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -391,14 +391,14 @@ def delete_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Deletes a pet
@@ -440,7 +440,7 @@ def delete_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -463,14 +463,14 @@ def delete_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Deletes a pet
@@ -512,7 +512,7 @@ def delete_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -535,15 +535,15 @@ def _delete_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -561,7 +561,7 @@ def _delete_pet_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -586,26 +586,26 @@ def _delete_pet_serialize(
@validate_call
def find_pets_by_status(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -636,8 +636,8 @@ def find_pets_by_status(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -654,26 +654,26 @@ def find_pets_by_status(
@validate_call
def find_pets_by_status_with_http_info(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -704,8 +704,8 @@ def find_pets_by_status_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -722,18 +722,18 @@ def find_pets_by_status_with_http_info(
@validate_call
def find_pets_by_status_without_preload_content(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Finds Pets by status
@@ -741,7 +741,7 @@ def find_pets_by_status_without_preload_content(
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -772,8 +772,8 @@ def find_pets_by_status_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -794,16 +794,16 @@ def _find_pets_by_status_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'status': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -829,7 +829,7 @@ def _find_pets_by_status_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -855,26 +855,26 @@ def _find_pets_by_status_serialize(
@validate_call
def find_pets_by_tags(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -906,8 +906,8 @@ def find_pets_by_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -924,26 +924,26 @@ def find_pets_by_tags(
@validate_call
def find_pets_by_tags_with_http_info(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -975,8 +975,8 @@ def find_pets_by_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -993,18 +993,18 @@ def find_pets_by_tags_with_http_info(
@validate_call
def find_pets_by_tags_without_preload_content(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""(Deprecated) Finds Pets by tags
@@ -1012,7 +1012,7 @@ def find_pets_by_tags_without_preload_content(
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1044,8 +1044,8 @@ def find_pets_by_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -1066,16 +1066,16 @@ def _find_pets_by_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'tags': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1101,7 +1101,7 @@ def _find_pets_by_tags_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1131,14 +1131,14 @@ def get_pet_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Find pet by ID
@@ -1177,7 +1177,7 @@ def get_pet_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1200,14 +1200,14 @@ def get_pet_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Find pet by ID
@@ -1246,7 +1246,7 @@ def get_pet_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1269,14 +1269,14 @@ def get_pet_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find pet by ID
@@ -1315,7 +1315,7 @@ def get_pet_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1338,15 +1338,15 @@ def _get_pet_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1370,7 +1370,7 @@ def _get_pet_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -1399,14 +1399,14 @@ def update_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Update an existing pet
@@ -1445,7 +1445,7 @@ def update_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1469,14 +1469,14 @@ def update_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Update an existing pet
@@ -1515,7 +1515,7 @@ def update_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1539,14 +1539,14 @@ def update_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Update an existing pet
@@ -1585,7 +1585,7 @@ def update_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1609,15 +1609,15 @@ def _update_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1647,7 +1647,7 @@ def _update_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1679,14 +1679,14 @@ def update_pet_with_form(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updates a pet in the store with form data
@@ -1731,7 +1731,7 @@ def update_pet_with_form(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1755,14 +1755,14 @@ def update_pet_with_form_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updates a pet in the store with form data
@@ -1807,7 +1807,7 @@ def update_pet_with_form_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1831,14 +1831,14 @@ def update_pet_with_form_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updates a pet in the store with form data
@@ -1883,7 +1883,7 @@ def update_pet_with_form_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1907,15 +1907,15 @@ def _update_pet_with_form_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1948,7 +1948,7 @@ def _update_pet_with_form_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -1975,18 +1975,18 @@ def upload_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image
@@ -2031,7 +2031,7 @@ def upload_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2050,18 +2050,18 @@ def upload_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image
@@ -2106,7 +2106,7 @@ def upload_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2125,18 +2125,18 @@ def upload_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image
@@ -2181,7 +2181,7 @@ def upload_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2204,15 +2204,15 @@ def _upload_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2252,7 +2252,7 @@ def _upload_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -2278,19 +2278,19 @@ def _upload_file_serialize(
def upload_file_with_required_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image (required)
@@ -2335,7 +2335,7 @@ def upload_file_with_required_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2353,19 +2353,19 @@ def upload_file_with_required_file(
def upload_file_with_required_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image (required)
@@ -2410,7 +2410,7 @@ def upload_file_with_required_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2428,19 +2428,19 @@ def upload_file_with_required_file_with_http_info(
def upload_file_with_required_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image (required)
@@ -2485,7 +2485,7 @@ def upload_file_with_required_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2508,15 +2508,15 @@ def _upload_file_with_required_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2556,7 +2556,7 @@ def _upload_file_with_required_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/store_api.py
index 73471217df00..d45fa277efb8 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/store_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictInt, StrictStr
-from typing import Dict
from typing_extensions import Annotated
from petstore_api.models.order import Order
@@ -45,14 +44,14 @@ def delete_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete purchase order by ID
@@ -91,7 +90,7 @@ def delete_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -113,14 +112,14 @@ def delete_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete purchase order by ID
@@ -159,7 +158,7 @@ def delete_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -181,14 +180,14 @@ def delete_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete purchase order by ID
@@ -227,7 +226,7 @@ def delete_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -249,15 +248,15 @@ def _delete_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -273,7 +272,7 @@ def _delete_order_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -300,16 +299,16 @@ def get_inventory(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> Dict[str, int]:
+ ) -> dict[str, int]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -343,8 +342,8 @@ def get_inventory(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -363,16 +362,16 @@ def get_inventory_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[Dict[str, int]]:
+ ) -> ApiResponse[dict[str, int]]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -406,8 +405,8 @@ def get_inventory_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -426,14 +425,14 @@ def get_inventory_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Returns pet inventories by status
@@ -469,8 +468,8 @@ def get_inventory_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -489,15 +488,15 @@ def _get_inventory_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -518,7 +517,7 @@ def _get_inventory_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -547,14 +546,14 @@ def get_order_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Find purchase order by ID
@@ -593,7 +592,7 @@ def get_order_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -616,14 +615,14 @@ def get_order_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Find purchase order by ID
@@ -662,7 +661,7 @@ def get_order_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -685,14 +684,14 @@ def get_order_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find purchase order by ID
@@ -731,7 +730,7 @@ def get_order_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -754,15 +753,15 @@ def _get_order_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -786,7 +785,7 @@ def _get_order_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -814,14 +813,14 @@ def place_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Place an order for a pet
@@ -860,7 +859,7 @@ def place_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -882,14 +881,14 @@ def place_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Place an order for a pet
@@ -928,7 +927,7 @@ def place_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -950,14 +949,14 @@ def place_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Place an order for a pet
@@ -996,7 +995,7 @@ def place_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -1018,15 +1017,15 @@ def _place_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1063,7 +1062,7 @@ def _place_order_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/user_api.py
index be61d536e31c..b1c924343f6b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api/user_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictStr
-from typing import List
from typing_extensions import Annotated
from petstore_api.models.user import User
@@ -45,14 +44,14 @@ def create_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> None:
"""Create user
@@ -91,7 +90,7 @@ def create_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -111,14 +110,14 @@ def create_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> ApiResponse[None]:
"""Create user
@@ -157,7 +156,7 @@ def create_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -177,14 +176,14 @@ def create_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> RESTResponseType:
"""Create user
@@ -223,7 +222,7 @@ def create_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -249,15 +248,15 @@ def _create_user_serialize(
]
_host = _hosts[_host_index]
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -286,7 +285,7 @@ def _create_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -310,18 +309,18 @@ def _create_user_serialize(
@validate_call
def create_users_with_array_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -329,7 +328,7 @@ def create_users_with_array_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -360,7 +359,7 @@ def create_users_with_array_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -376,18 +375,18 @@ def create_users_with_array_input(
@validate_call
def create_users_with_array_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -395,7 +394,7 @@ def create_users_with_array_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -426,7 +425,7 @@ def create_users_with_array_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -442,18 +441,18 @@ def create_users_with_array_input_with_http_info(
@validate_call
def create_users_with_array_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -461,7 +460,7 @@ def create_users_with_array_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -492,7 +491,7 @@ def create_users_with_array_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -512,16 +511,16 @@ def _create_users_with_array_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -550,7 +549,7 @@ def _create_users_with_array_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,18 +573,18 @@ def _create_users_with_array_input_serialize(
@validate_call
def create_users_with_list_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -593,7 +592,7 @@ def create_users_with_list_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -624,7 +623,7 @@ def create_users_with_list_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -640,18 +639,18 @@ def create_users_with_list_input(
@validate_call
def create_users_with_list_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -659,7 +658,7 @@ def create_users_with_list_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -690,7 +689,7 @@ def create_users_with_list_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -706,18 +705,18 @@ def create_users_with_list_input_with_http_info(
@validate_call
def create_users_with_list_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -725,7 +724,7 @@ def create_users_with_list_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -756,7 +755,7 @@ def create_users_with_list_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -776,16 +775,16 @@ def _create_users_with_list_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -814,7 +813,7 @@ def _create_users_with_list_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -842,14 +841,14 @@ def delete_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete user
@@ -888,7 +887,7 @@ def delete_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -910,14 +909,14 @@ def delete_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete user
@@ -956,7 +955,7 @@ def delete_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -978,14 +977,14 @@ def delete_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete user
@@ -1024,7 +1023,7 @@ def delete_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1046,15 +1045,15 @@ def _delete_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1070,7 +1069,7 @@ def _delete_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1098,14 +1097,14 @@ def get_user_by_name(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> User:
"""Get user by user name
@@ -1144,7 +1143,7 @@ def get_user_by_name(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1167,14 +1166,14 @@ def get_user_by_name_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[User]:
"""Get user by user name
@@ -1213,7 +1212,7 @@ def get_user_by_name_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1236,14 +1235,14 @@ def get_user_by_name_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Get user by user name
@@ -1282,7 +1281,7 @@ def get_user_by_name_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1305,15 +1304,15 @@ def _get_user_by_name_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1337,7 +1336,7 @@ def _get_user_by_name_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1366,14 +1365,14 @@ def login_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Logs user into the system
@@ -1415,7 +1414,7 @@ def login_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1438,14 +1437,14 @@ def login_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Logs user into the system
@@ -1487,7 +1486,7 @@ def login_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1510,14 +1509,14 @@ def login_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs user into the system
@@ -1559,7 +1558,7 @@ def login_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1582,15 +1581,15 @@ def _login_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1620,7 +1619,7 @@ def _login_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1647,14 +1646,14 @@ def logout_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Logs out current logged in user session
@@ -1690,7 +1689,7 @@ def logout_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1709,14 +1708,14 @@ def logout_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Logs out current logged in user session
@@ -1752,7 +1751,7 @@ def logout_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1771,14 +1770,14 @@ def logout_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs out current logged in user session
@@ -1814,7 +1813,7 @@ def logout_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1833,15 +1832,15 @@ def _logout_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1855,7 +1854,7 @@ def _logout_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1884,14 +1883,14 @@ def update_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updated user
@@ -1933,7 +1932,7 @@ def update_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1956,14 +1955,14 @@ def update_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updated user
@@ -2005,7 +2004,7 @@ def update_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2028,14 +2027,14 @@ def update_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updated user
@@ -2077,7 +2076,7 @@ def update_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2100,15 +2099,15 @@ def _update_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2139,7 +2138,7 @@ def _update_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api_client.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api_client.py
index d388566cbbe2..282fc86149b9 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/api_client.py
@@ -23,7 +23,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from petstore_api.configuration import Configuration
@@ -40,7 +40,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -286,7 +286,7 @@ def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -434,16 +434,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -478,7 +478,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -508,7 +508,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -542,7 +542,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -575,7 +575,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/configuration.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/configuration.py
index e50683d07366..19d21c6a8883 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/configuration.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/configuration.py
@@ -16,7 +16,7 @@
from logging import FileHandler
import multiprocessing
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
import urllib3
@@ -29,7 +29,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -126,13 +126,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -266,16 +266,16 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
signing_info: Optional[HttpSigningConfiguration]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[Union[int, urllib3.util.retry.Retry]] = None,
@@ -425,7 +425,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -668,7 +668,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -721,7 +721,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_any_type.py
index 19db20137bc4..8664dd11b01d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_any_type.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_class.py
index 2f03e1fa1758..b92c83ddda06 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.pet import Pet
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,11 +28,11 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
""" # noqa: E501
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_object.py
index d23fd87e51f3..2f1556c5e9ec 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_with_description_only.py
index b1f42400b676..f12bbeaec7f8 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/additional_properties_with_description_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_super_model.py
index 86a856c01520..50ed4f60e43a 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_super_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_super_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AllOfSuperModel(BaseModel):
AllOfSuperModel
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_with_single_ref.py
index 371730978cfa..dada4257ce40 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_with_single_ref.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/all_of_with_single_ref.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.single_ref_type import SingleRefType
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class AllOfWithSingleRef(BaseModel):
""" # noqa: E501
username: Optional[StrictStr] = None
single_ref_type: Optional[SingleRefType] = Field(default=None, alias="SingleRefType")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["username", "SingleRefType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["username", "SingleRefType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/animal.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/animal.py
index 562423002c0a..e370fb2e82d8 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/animal.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/animal.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class Animal(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: Optional[StrictStr] = 'red'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -50,12 +50,12 @@ class Animal(BaseModel):
__discriminator_property_name: ClassVar[str] = 'className'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Cat': 'Cat','Dog': 'Dog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -76,7 +76,7 @@ def from_json(cls, json_str: str) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -104,7 +104,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[Cat, Dog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_color.py
index f6d277e79498..2039c0de8af9 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_color.py
@@ -18,30 +18,30 @@
import pprint
import re # noqa: F401
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import List, Optional
+from typing import Optional
from typing_extensions import Annotated
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- anyof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- anyof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Optional[Union[List[int], str]] = None
+ actual_instance: Optional[Union[list[int], str]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "List[int]", "str" }
+ any_of_schemas: set[str] = { "list[int]", "str" }
model_config = {
"validate_assignment": True,
@@ -62,13 +62,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.model_construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -82,12 +82,12 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -95,7 +95,7 @@ def from_json(cls, json_str: str) -> Self:
"""Returns the object represented by the json string"""
instance = cls.model_construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -104,7 +104,7 @@ def from_json(cls, json_str: str) -> Self:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -125,7 +125,7 @@ def from_json(cls, json_str: str) -> Self:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -139,7 +139,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_pig.py
index c949e136f415..0211d0291d94 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/any_of_pig.py
@@ -21,7 +21,7 @@
from typing import Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ any_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = {
"validate_assignment": True,
@@ -80,7 +80,7 @@ def actual_instance_must_validate_anyof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -117,7 +117,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_model.py
index f290c6a19437..b0b1081e2e0b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ArrayOfArrayOfModel(BaseModel):
"""
ArrayOfArrayOfModel
""" # noqa: E501
- another_property: Optional[List[List[Tag]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["another_property"]
+ another_property: Optional[list[list[Tag]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["another_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_number_only.py
index bf87ebab7ef8..91d1b814abe3 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class ArrayOfArrayOfNumberOnly(BaseModel):
"""
ArrayOfArrayOfNumberOnly
""" # noqa: E501
- array_array_number: Optional[List[List[StrictFloat]]] = Field(default=None, alias="ArrayArrayNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["ArrayArrayNumber"]
+ array_array_number: Optional[list[list[StrictFloat]]] = Field(default=None, alias="ArrayArrayNumber")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["ArrayArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_map_model.py
index 5f2639374f32..087fd031ad5f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_map_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
""" # noqa: E501
- array_of_map_property: Optional[List[Dict[str, Tag]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["array_of_map_property"]
+ array_of_map_property: Optional[list[dict[str, Tag]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["array_of_map_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_number_only.py
index c6c50aed2d41..fa82d1aa49d0 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class ArrayOfNumberOnly(BaseModel):
"""
ArrayOfNumberOnly
""" # noqa: E501
- array_number: Optional[List[StrictFloat]] = Field(default=None, alias="ArrayNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["ArrayNumber"]
+ array_number: Optional[list[StrictFloat]] = Field(default=None, alias="ArrayNumber")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["ArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_test.py
index bbe20c814a4d..7406b87ce878 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/array_test.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.read_only_first import ReadOnlyFirst
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,12 +29,12 @@ class ArrayTest(BaseModel):
"""
ArrayTest
""" # noqa: E501
- array_of_string: Optional[Annotated[List[StrictStr], Field(min_length=0, max_length=3)]] = None
- array_of_nullable_float: Optional[List[Optional[StrictFloat]]] = None
- array_array_of_integer: Optional[List[List[StrictInt]]] = None
- array_array_of_model: Optional[List[List[ReadOnlyFirst]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
+ array_of_string: Optional[Annotated[list[StrictStr], Field(min_length=0, max_length=3)]] = None
+ array_of_nullable_float: Optional[list[Optional[StrictFloat]]] = None
+ array_array_of_integer: Optional[list[list[StrictInt]]] = None
+ array_array_of_model: Optional[list[list[ReadOnlyFirst]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/base_discriminator.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/base_discriminator.py
index c1111f98976d..1124f17136e8 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/base_discriminator.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/base_discriminator.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class BaseDiscriminator(BaseModel):
BaseDiscriminator
""" # noqa: E501
type_name: Optional[StrictStr] = Field(default=None, alias="_typeName")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class BaseDiscriminator(BaseModel):
__discriminator_property_name: ClassVar[str] = '_typeName'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'string': 'PrimitiveString','Info': 'Info'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -103,7 +103,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/basque_pig.py
index d61619ca2efb..8296939aa774 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/basque_pig.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/basque_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class BasquePig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of BasquePig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of BasquePig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/bathing.py
index c4d595a498b8..80f970898953 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/bathing.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/bathing.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class Bathing(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bathing from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bathing from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/capitalization.py
index 1f38a7124a7f..6d2e10dfa13b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/capitalization.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/capitalization.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,8 +33,8 @@ class Capitalization(BaseModel):
capital_snake: Optional[StrictStr] = Field(default=None, alias="Capital_Snake")
sca_eth_flow_points: Optional[StrictStr] = Field(default=None, alias="SCA_ETH_Flow_Points")
att_name: Optional[StrictStr] = Field(default=None, description="Name of the pet ", alias="ATT_NAME")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Capitalization from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Capitalization from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/cat.py
index dfdf659272c0..c113268eaa9c 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/cat.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/cat.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Cat(Animal):
Cat
""" # noqa: E501
declawed: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color", "declawed"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color", "declawed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Cat from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Cat from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/category.py
index 425e409c7adc..55c20e9c42cd 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/category.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/category.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_all_of_ref.py
index f03de1a2c7fb..9874002470b5 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class CircularAllOfRef(BaseModel):
CircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- second_circular_all_of_ref: Optional[List[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name", "secondCircularAllOfRef"]
+ second_circular_all_of_ref: Optional[list[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name", "secondCircularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_reference_model.py
index 4a46e13580af..7bf706aa6e99 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_reference_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/circular_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class CircularReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[FirstRef] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/class_model.py
index 752706128969..37e996bbe35b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/class_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/class_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ClassModel(BaseModel):
Model for testing model with \"_class\" property
""" # noqa: E501
var_class: Optional[StrictStr] = Field(default=None, alias="_class")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_class"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ClassModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ClassModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/client.py
index cbbea6d33af4..359f4f703b6f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/client.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/client.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Client(BaseModel):
Client
""" # noqa: E501
client: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["client"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["client"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Client from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Client from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/color.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/color.py
index bb740fb597d4..b3c3404d00f7 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/color.py
@@ -16,26 +16,26 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- oneof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- oneof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
- actual_instance: Optional[Union[List[int], str]] = None
- one_of_schemas: Set[str] = { "List[int]", "str" }
+ actual_instance: Optional[Union[list[int], str]] = None
+ one_of_schemas: set[str] = { "list[int]", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -61,13 +61,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.model_construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -81,15 +81,15 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -102,7 +102,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -111,7 +111,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -132,10 +132,10 @@ def from_json(cls, json_str: Optional[str]) -> Self:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -149,7 +149,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature.py
index e8bcab1ec3f1..c55567257e88 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature.py
@@ -19,9 +19,9 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
+from typing import Any, ClassVar, Union
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class Creature(BaseModel):
""" # noqa: E501
info: CreatureInfo
type: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["info", "type"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["info", "type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -50,12 +50,12 @@ class Creature(BaseModel):
__discriminator_property_name: ClassVar[str] = 'type'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Hunting__Dog': 'HuntingDog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -76,7 +76,7 @@ def from_json(cls, json_str: str) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -107,7 +107,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[HuntingDog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature_info.py
index ba91bd0874f3..6f8678f84344 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature_info.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/creature_info.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class CreatureInfo(BaseModel):
CreatureInfo
""" # noqa: E501
name: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CreatureInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CreatureInfo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/danish_pig.py
index 0f9f43773ae7..7bb81b6446f1 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/danish_pig.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/danish_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class DanishPig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
size: StrictInt
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "size"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "size"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DanishPig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DanishPig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/deprecated_object.py
index f310e64b7a83..bdb5acb5887d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/deprecated_object.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/deprecated_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class DeprecatedObject(BaseModel):
DeprecatedObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_sub.py
index 2250170a4633..c31b01a139eb 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_sub.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_sub.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from petstore_api.models.discriminator_all_of_super import DiscriminatorAllOfSuper
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class DiscriminatorAllOfSub(DiscriminatorAllOfSuper):
"""
DiscriminatorAllOfSub
""" # noqa: E501
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["elementType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_super.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_super.py
index 5dcc0b569e8f..0ac2c6ece21f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_super.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/discriminator_all_of_super.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,8 +33,8 @@ class DiscriminatorAllOfSuper(BaseModel):
DiscriminatorAllOfSuper
""" # noqa: E501
element_type: StrictStr = Field(alias="elementType")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["elementType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -48,12 +48,12 @@ class DiscriminatorAllOfSuper(BaseModel):
__discriminator_property_name: ClassVar[str] = 'elementType'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'DiscriminatorAllOfSub': 'DiscriminatorAllOfSub'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -102,7 +102,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dog.py
index a5c869b8de82..97a827ccb393 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dog.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dog.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Dog(Animal):
Dog
""" # noqa: E501
breed: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color", "breed"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color", "breed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Dog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Dog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dummy_model.py
index 9fdf057cdb63..55e8bc485bb1 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dummy_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/dummy_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class DummyModel(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SelfReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DummyModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DummyModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_arrays.py
index 270f540ef1b6..2d8b80c022dd 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_arrays.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class EnumArrays(BaseModel):
EnumArrays
""" # noqa: E501
just_symbol: Optional[StrictStr] = None
- array_enum: Optional[List[StrictStr]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["just_symbol", "array_enum"]
+ array_enum: Optional[list[StrictStr]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["just_symbol", "array_enum"]
@field_validator('just_symbol')
def just_symbol_validate_enum(cls, value):
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -102,7 +102,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_ref_with_default_value.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_ref_with_default_value.py
index d35a7f9d426a..d1051ddaa7a4 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_ref_with_default_value.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_ref_with_default_value.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.data_output_format import DataOutputFormat
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class EnumRefWithDefaultValue(BaseModel):
EnumRefWithDefaultValue
""" # noqa: E501
report_format: Optional[DataOutputFormat] = DataOutputFormat.JSON
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["report_format"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["report_format"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_test.py
index b38efd78ef7e..47285705cfec 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_test.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/enum_test.py
@@ -18,14 +18,14 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.enum_number_vendor_ext import EnumNumberVendorExt
from petstore_api.models.enum_string_vendor_ext import EnumStringVendorExt
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_default_value import OuterEnumDefaultValue
from petstore_api.models.outer_enum_integer import OuterEnumInteger
from petstore_api.models.outer_enum_integer_default_value import OuterEnumIntegerDefaultValue
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -46,8 +46,8 @@ class EnumTest(BaseModel):
outer_enum_integer_default_value: Optional[OuterEnumIntegerDefaultValue] = Field(default=OuterEnumIntegerDefaultValue.NUMBER_0, alias="outerEnumIntegerDefaultValue")
enum_number_vendor_ext: Optional[EnumNumberVendorExt] = Field(default=None, alias="enumNumberVendorExt")
enum_string_vendor_ext: Optional[EnumStringVendorExt] = Field(default=None, alias="enumStringVendorExt")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
@field_validator('enum_string')
def enum_string_validate_enum(cls, value):
@@ -137,7 +137,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -170,7 +170,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/feeding.py
index 3efa9e0ede0e..ed5753ed6bf2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/feeding.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/feeding.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class Feeding(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Feeding from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Feeding from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file.py
index b7670595acb2..bd9639b2a012 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class File(BaseModel):
Must be named `File` for test.
""" # noqa: E501
source_uri: Optional[StrictStr] = Field(default=None, description="Test capitalization", alias="sourceURI")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["sourceURI"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["sourceURI"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of File from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of File from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file_schema_test_class.py
index 80da509938d5..fffa59bcf3cc 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/file_schema_test_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,9 +29,9 @@ class FileSchemaTestClass(BaseModel):
FileSchemaTestClass
""" # noqa: E501
file: Optional[File] = None
- files: Optional[List[File]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["file", "files"]
+ files: Optional[list[File]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["file", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/first_ref.py
index 50d561621b36..ba2b14e91374 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/first_ref.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/first_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FirstRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SecondRef] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FirstRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FirstRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo.py
index 2d15a0729446..bf3caa8fa2b2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Foo(BaseModel):
Foo
""" # noqa: E501
bar: Optional[StrictStr] = 'bar'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Foo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Foo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo_get_default_response.py
index b8ab0cd0dfd1..df25097e4273 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo_get_default_response.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/foo_get_default_response.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.foo import Foo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FooGetDefaultResponse(BaseModel):
FooGetDefaultResponse
""" # noqa: E501
string: Optional[Foo] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["string"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/format_test.py
index f3f6888b0c7f..eda07f185560 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/format_test.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/format_test.py
@@ -20,10 +20,10 @@
from datetime import date, datetime
from decimal import Decimal
from pydantic import BaseModel, ConfigDict, Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional, Tuple, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -41,15 +41,15 @@ class FormatTest(BaseModel):
string: Optional[Annotated[str, Field(strict=True)]] = None
string_with_double_quote_pattern: Optional[Annotated[str, Field(strict=True)]] = None
byte: Optional[Union[StrictBytes, StrictStr]] = None
- binary: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None
+ binary: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None
var_date: date = Field(alias="date")
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
uuid: Optional[UUID] = None
password: Annotated[str, Field(min_length=10, strict=True, max_length=64)]
pattern_with_digits: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string that is a 10 digit number. Can have leading zeros.")
pattern_with_digits_and_delimiter: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
@field_validator('string')
def string_validate_regular_expression(cls, value):
@@ -124,7 +124,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FormatTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -135,7 +135,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -152,7 +152,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FormatTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/has_only_read_only.py
index 259ee97dcbab..e19acc704229 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/has_only_read_only.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/has_only_read_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class HasOnlyReadOnly(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
foo: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar", "foo"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar", "foo"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"foo",
"additional_properties",
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/health_check_result.py
index e333321a7617..dbb9b9750d87 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/health_check_result.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/health_check_result.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class HealthCheckResult(BaseModel):
Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model.
""" # noqa: E501
nullable_message: Optional[StrictStr] = Field(default=None, alias="NullableMessage")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["NullableMessage"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["NullableMessage"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/hunting_dog.py
index 15c26d355520..6f9238baff32 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/hunting_dog.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/hunting_dog.py
@@ -18,10 +18,10 @@
import json
from pydantic import ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature import Creature
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class HuntingDog(Creature):
HuntingDog
""" # noqa: E501
is_trained: Optional[StrictBool] = Field(default=None, alias="isTrained")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["info", "type", "isTrained"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["info", "type", "isTrained"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HuntingDog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HuntingDog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/info.py
index 71862c10b392..b1c2e37a7b6d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/info.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/info.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Info(BaseDiscriminator):
Info
""" # noqa: E501
val: Optional[BaseDiscriminator] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName", "val"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName", "val"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Info from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Info from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/inner_dict_with_property.py
index 093d1be68617..d5206c1ea9f6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/inner_dict_with_property.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
""" # noqa: E501
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["aProperty"]
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["aProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/input_all_of.py
index 4d1ff0e87aac..e85aca75ae20 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/input_all_of.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class InputAllOf(BaseModel):
"""
InputAllOf
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InputAllOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InputAllOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/int_or_string.py
index f2a5a0a2d4a3..02180a2d6a53 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/int_or_string.py
@@ -16,10 +16,10 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -33,7 +33,7 @@ class IntOrString(BaseModel):
# data type: str
oneof_schema_2_validator: Optional[StrictStr] = None
actual_instance: Optional[Union[int, str]] = None
- one_of_schemas: Set[str] = { "int", "str" }
+ one_of_schemas: set[str] = { "int", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -78,7 +78,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -126,7 +126,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], int, str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], int, str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/list_class.py
index 3c64d3024686..415b50cf9f56 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/list_class.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/list_class.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ListClass(BaseModel):
ListClass
""" # noqa: E501
var_123_list: Optional[StrictStr] = Field(default=None, alias="123-list")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["123-list"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["123-list"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ListClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ListClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_of_array_of_model.py
index c6018ae272c6..b6c2f85aaa17 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
""" # noqa: E501
- shop_id_to_org_online_lip_map: Optional[Dict[str, List[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["shopIdToOrgOnlineLipMap"]
+ shop_id_to_org_online_lip_map: Optional[dict[str, list[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["shopIdToOrgOnlineLipMap"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_test.py
index 77569b9bf3b4..544680a197be 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/map_test.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,12 +27,12 @@ class MapTest(BaseModel):
"""
MapTest
""" # noqa: E501
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@field_validator('map_of_enum_string')
def map_of_enum_string_validate_enum(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/mixed_properties_and_additional_properties_class.py
index 65da9a205120..c61d4557e8f2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -19,10 +19,10 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,9 +32,9 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
""" # noqa: E501
uuid: Optional[UUID] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["uuid", "dateTime", "map"]
+ map: Optional[dict[str, Animal]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["uuid", "dateTime", "map"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model200_response.py
index a8f10880da53..5e764264f9b2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model200_response.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model200_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Model200Response(BaseModel):
""" # noqa: E501
name: Optional[StrictInt] = None
var_class: Optional[StrictStr] = Field(default=None, alias="class")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name", "class"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name", "class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Model200Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Model200Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_api_response.py
index 45960f5877ff..8b1bc67d6ebe 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_api_response.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_api_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class ModelApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["code", "type", "message"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["code", "type", "message"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_field.py
index bf6560e93e13..80e7cfd91d3a 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_field.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_field.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ModelField(BaseModel):
ModelField
""" # noqa: E501
var_field: Optional[StrictStr] = Field(default=None, alias="field")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["field"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["field"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelField from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelField from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_return.py
index d564c896d7db..30c65c5d53ee 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_return.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/model_return.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ModelReturn(BaseModel):
Model for testing reserved words
""" # noqa: E501
var_return: Optional[StrictInt] = Field(default=None, alias="return")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["return"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["return"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelReturn from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelReturn from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/multi_arrays.py
index e1764bac50af..d5c8e29094d2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/multi_arrays.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,10 +29,10 @@ class MultiArrays(BaseModel):
"""
MultiArrays
""" # noqa: E501
- tags: Optional[List[Tag]] = None
- files: Optional[List[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["tags", "files"]
+ tags: Optional[list[Tag]] = None
+ files: Optional[list[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["tags", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MultiArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -97,7 +97,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MultiArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/name.py
index a5c21f36b2b9..79d221125478 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/name.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class Name(BaseModel):
snake_case: Optional[StrictInt] = None
var_property: Optional[StrictStr] = Field(default=None, alias="property")
var_123_number: Optional[StrictInt] = Field(default=None, alias="123Number")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name", "snake_case", "property", "123Number"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name", "snake_case", "property", "123Number"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Name from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"snake_case",
"var_123_number",
"additional_properties",
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Name from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_class.py
index 2504f4c359f5..84d2b7734790 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_class.py
@@ -19,8 +19,8 @@
from datetime import date, datetime
from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,14 +35,14 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[List[Dict[str, Any]]] = None
- array_and_items_nullable_prop: Optional[List[Optional[Dict[str, Any]]]] = None
- array_items_nullable: Optional[List[Optional[Dict[str, Any]]]] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- object_items_nullable: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
+ array_nullable_prop: Optional[list[dict[str, Any]]] = None
+ array_and_items_nullable_prop: Optional[list[Optional[dict[str, Any]]]] = None
+ array_items_nullable: Optional[list[Optional[dict[str, Any]]]] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ object_items_nullable: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
model_config = ConfigDict(
validate_by_name=True,
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_property.py
index 0d838a27738e..5216a6246ef7 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_property.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/nullable_property.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class NullableProperty(BaseModel):
""" # noqa: E501
id: StrictInt
name: Optional[Annotated[str, Field(strict=True)]]
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
@field_validator('name')
def name_validate_regular_expression(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -78,7 +78,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/number_only.py
index e9c7ef6ddb2f..b411727d51ad 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/number_only.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class NumberOnly(BaseModel):
NumberOnly
""" # noqa: E501
just_number: Optional[StrictFloat] = Field(default=None, alias="JustNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["JustNumber"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["JustNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_to_test_additional_properties.py
index 0d8dd42a4b64..9990828cee5f 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_to_test_additional_properties.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_to_test_additional_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ObjectToTestAdditionalProperties(BaseModel):
Minimal object
""" # noqa: E501
var_property: Optional[StrictBool] = Field(default=False, description="Property", alias="property")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["property"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_with_deprecated_fields.py
index 9b9ff8540e75..b5955ffa6403 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/object_with_deprecated_fields.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.deprecated_object import DeprecatedObject
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,9 +31,9 @@ class ObjectWithDeprecatedFields(BaseModel):
uuid: Optional[StrictStr] = None
id: Optional[StrictFloat] = None
deprecated_ref: Optional[DeprecatedObject] = Field(default=None, alias="deprecatedRef")
- bars: Optional[List[StrictStr]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["uuid", "id", "deprecatedRef", "bars"]
+ bars: Optional[list[StrictStr]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["uuid", "id", "deprecatedRef", "bars"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -67,7 +67,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/one_of_enum_string.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/one_of_enum_string.py
index f180178737db..4d35cc225469 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/one_of_enum_string.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/one_of_enum_string.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.enum_string1 import EnumString1
from petstore_api.models.enum_string2 import EnumString2
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
ONEOFENUMSTRING_ONE_OF_SCHEMAS = ["EnumString1", "EnumString2"]
@@ -34,7 +34,7 @@ class OneOfEnumString(BaseModel):
# data type: EnumString2
oneof_schema_2_validator: Optional[EnumString2] = None
actual_instance: Optional[Union[EnumString1, EnumString2]] = None
- one_of_schemas: Set[str] = { "EnumString1", "EnumString2" }
+ one_of_schemas: set[str] = { "EnumString1", "EnumString2" }
model_config = ConfigDict(
validate_assignment=True,
@@ -77,7 +77,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -119,7 +119,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], EnumString1, EnumString2]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], EnumString1, EnumString2]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/order.py
index c7c9066c9cc2..a4d13984f575 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/order.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/order.py
@@ -19,8 +19,8 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Order from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Order from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_composite.py
index 2272cc9f4f9c..f02b63d0052e 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_composite.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_composite.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class OuterComposite(BaseModel):
my_number: Optional[StrictFloat] = None
my_string: Optional[StrictStr] = None
my_boolean: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["my_number", "my_string", "my_boolean"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["my_number", "my_string", "my_boolean"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterComposite from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterComposite from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_object_with_enum_property.py
index dd6a05e25bff..cb47a63cf871 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_object_with_enum_property.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/outer_object_with_enum_property.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_integer import OuterEnumInteger
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class OuterObjectWithEnumProperty(BaseModel):
""" # noqa: E501
str_value: Optional[OuterEnum] = None
value: OuterEnumInteger
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["str_value", "value"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["str_value", "value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent.py
index 8a9e22c1656d..ef4e59612632 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class Parent(BaseModel):
"""
Parent
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Parent from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Parent from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent_with_optional_dict.py
index 742936312735..3f3c398dd224 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/parent_with_optional_dict.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pet.py
index 6d117df625b0..7154fcded7b6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pet.py
@@ -18,11 +18,11 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,11 +33,11 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
category: Optional[Category] = None
name: StrictStr
- photo_urls: Annotated[List[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: Annotated[list[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -70,7 +70,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -108,7 +108,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pig.py
index 06798245b8fe..ee1b3f716534 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pig.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -34,7 +34,7 @@ class Pig(BaseModel):
# data type: DanishPig
oneof_schema_2_validator: Optional[DanishPig] = None
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
- one_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ one_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = ConfigDict(
validate_assignment=True,
@@ -42,7 +42,7 @@ class Pig(BaseModel):
)
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
}
def __init__(self, *args, **kwargs) -> None:
@@ -80,7 +80,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -137,7 +137,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pony_sizes.py
index 4a231ca7cace..03d46f24c69d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pony_sizes.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/pony_sizes.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.type import Type
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class PonySizes(BaseModel):
PonySizes
""" # noqa: E501
type: Optional[Type] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["type"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PonySizes from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PonySizes from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/poop_cleaning.py
index aed809a9fe0b..d96f8de6563e 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/poop_cleaning.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/poop_cleaning.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class PoopCleaning(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PoopCleaning from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PoopCleaning from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/primitive_string.py
index 1cee0bb8d9cf..9c16f68c4554 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/primitive_string.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/primitive_string.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class PrimitiveString(BaseDiscriminator):
PrimitiveString
""" # noqa: E501
value: Optional[StrictStr] = Field(default=None, alias="_value")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName", "_value"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName", "_value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PrimitiveString from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PrimitiveString from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_map.py
index e72e32123334..87695639bdbd 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_map.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class PropertyMap(BaseModel):
"""
PropertyMap
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyMap from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyMap from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_name_collision.py
index 07b4652d12f0..51771d81fa70 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_name_collision.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/property_name_collision.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class PropertyNameCollision(BaseModel):
underscore_type: Optional[StrictStr] = Field(default=None, alias="_type")
type: Optional[StrictStr] = None
type_with_underscore: Optional[StrictStr] = Field(default=None, alias="type_")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_type", "type", "type_"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_type", "type", "type_"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/read_only_first.py
index debfe69300dc..de84c323cd34 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/read_only_first.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/read_only_first.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class ReadOnlyFirst(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
baz: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar", "baz"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar", "baz"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"additional_properties",
])
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_circular_all_of_ref.py
index 19116213fd5d..bc0976bf88a9 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class SecondCircularAllOfRef(BaseModel):
SecondCircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- circular_all_of_ref: Optional[List[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name", "circularAllOfRef"]
+ circular_all_of_ref: Optional[list[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name", "circularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_ref.py
index ef17a11429a9..fe83233f02cc 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_ref.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/second_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class SecondRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
circular_ref: Optional[CircularReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "circular_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "circular_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/self_reference_model.py
index bd49a84093b5..50643b4782eb 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/self_reference_model.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/self_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class SelfReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[DummyModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_model_name.py
index 528c09f6c18f..43d77bb2f06b 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_model_name.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_model_name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class SpecialModelName(BaseModel):
SpecialModelName
""" # noqa: E501
special_property_name: Optional[StrictInt] = Field(default=None, alias="$special[property.name]")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["$special[property.name]"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["$special[property.name]"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialModelName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialModelName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_name.py
index c667d1e9e4c6..c7a24fdba835 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_name.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/special_name.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.category import Category
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class SpecialName(BaseModel):
var_property: Optional[StrictInt] = Field(default=None, alias="property")
var_async: Optional[Category] = Field(default=None, alias="async")
var_schema: Optional[StrictStr] = Field(default=None, description="pet status in the store", alias="schema")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["property", "async", "schema"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["property", "async", "schema"]
@field_validator('var_schema')
def var_schema_validate_enum(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tag.py
index 7b636a76d02e..6ff1efaa4e70 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tag.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tag.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task.py
index b7a3153d1ea5..5c6d4d998895 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from uuid import UUID
from petstore_api.models.task_activity import TaskActivity
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class Task(BaseModel):
""" # noqa: E501
id: UUID
activity: TaskActivity
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "activity"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "activity"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Task from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Task from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task_activity.py
index cc1e1fc5a60f..51bec8a6c3f0 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/task_activity.py
@@ -16,12 +16,12 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -37,7 +37,7 @@ class TaskActivity(BaseModel):
# data type: Bathing
oneof_schema_3_validator: Optional[Bathing] = None
actual_instance: Optional[Union[Bathing, Feeding, PoopCleaning]] = None
- one_of_schemas: Set[str] = { "Bathing", "Feeding", "PoopCleaning" }
+ one_of_schemas: set[str] = { "Bathing", "Feeding", "PoopCleaning" }
model_config = ConfigDict(
validate_assignment=True,
@@ -85,7 +85,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -133,7 +133,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], Bathing, Feeding, PoopCleaning]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], Bathing, Feeding, PoopCleaning]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model400_response.py
index 6c4ac684baeb..a1f14e8a2173 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model400_response.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model400_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestErrorResponsesWithModel400Response(BaseModel):
TestErrorResponsesWithModel400Response
""" # noqa: E501
reason400: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["reason400"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["reason400"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model404_response.py
index 225e27ea0789..5166582c4c11 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model404_response.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_error_responses_with_model404_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestErrorResponsesWithModel404Response(BaseModel):
TestErrorResponsesWithModel404Response
""" # noqa: E501
reason404: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["reason404"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["reason404"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 67f893c75448..2ba526ab52ba 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
""" # noqa: E501
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["someProperty"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["someProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_model_with_enum_default.py
index cce5ffb967e7..cc4d8ce59ae2 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_model_with_enum_default.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_model_with_enum_default.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.test_enum import TestEnum
from petstore_api.models.test_enum_with_default import TestEnumWithDefault
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class TestModelWithEnumDefault(BaseModel):
test_enum_with_default: Optional[TestEnumWithDefault] = TestEnumWithDefault.ZWEI
test_string_with_default: Optional[StrictStr] = 'ahoy matey'
test_inline_defined_enum_with_default: Optional[StrictStr] = 'B'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
@field_validator('test_inline_defined_enum_with_default')
def test_inline_defined_enum_with_default_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_object_for_multipart_requests_request_marker.py
index 33bf3764d782..b9bc9abd1e97 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_object_for_multipart_requests_request_marker.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/test_object_for_multipart_requests_request_marker.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestObjectForMultipartRequestsRequestMarker(BaseModel):
TestObjectForMultipartRequestsRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tiger.py
index 0962151b05ba..4fce3fe90fb6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tiger.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/tiger.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Tiger(BaseModel):
Tiger
""" # noqa: E501
skill: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["skill"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["skill"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tiger from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tiger from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index cf6878baa1b9..1559c48ddb2c 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[CreatureInfo]]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[CreatureInfo]]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index 9e096d408cb6..b1ed33be0977 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[StrictStr]]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[StrictStr]]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/upload_file_with_additional_properties_request_object.py
index 1fd25f6d3f7b..116c7434234d 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/upload_file_with_additional_properties_request_object.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/upload_file_with_additional_properties_request_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
Additional object
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/user.py
index d0c58815f3ce..21a278fc5a54 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/user.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/user.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, description="User Status", alias="userStatus")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
model_config = ConfigDict(
validate_by_name=True,
@@ -59,7 +59,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of User from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -70,7 +70,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of User from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/uuid_with_pattern.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/uuid_with_pattern.py
index e86c87f16359..cb00d5375e4e 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/uuid_with_pattern.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/uuid_with_pattern.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class UuidWithPattern(BaseModel):
UuidWithPattern
""" # noqa: E501
id: Optional[UUID] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id"]
@field_validator('id')
def id_validate_regular_expression(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/with_nested_one_of.py
index d3127ac468c0..54ecffec4ac6 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/with_nested_one_of.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/models/with_nested_one_of.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.one_of_enum_string import OneOfEnumString
from petstore_api.models.pig import Pig
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,8 +32,8 @@ class WithNestedOneOf(BaseModel):
size: Optional[StrictInt] = None
nested_pig: Optional[Pig] = None
nested_oneof_enum_string: Optional[OneOfEnumString] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -67,7 +67,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/signing.py b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/signing.py
index e0ef058f4677..c52fe689fc96 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/petstore_api/signing.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/petstore_api/signing.py
@@ -22,7 +22,7 @@
import os
import re
from time import time
-from typing import List, Optional, Union
+from typing import Optional, Union
from urllib.parse import urlencode, urlparse
# The constants below define a subset of HTTP headers that can be included in the
@@ -128,7 +128,7 @@ def __init__(self,
signing_scheme: str,
private_key_path: str,
private_key_passphrase: Union[None, str]=None,
- signed_headers: Optional[List[str]]=None,
+ signed_headers: Optional[list[str]]=None,
signing_algorithm: Optional[str]=None,
hash_algorithm: Optional[str]=None,
signature_max_validity: Optional[timedelta]=None,
diff --git a/samples/openapi3/client/petstore/python-lazyImports/tests/test_deserialization.py b/samples/openapi3/client/petstore/python-lazyImports/tests/test_deserialization.py
index a8ebc21126cd..52f19bd78e7a 100644
--- a/samples/openapi3/client/petstore/python-lazyImports/tests/test_deserialization.py
+++ b/samples/openapi3/client/petstore/python-lazyImports/tests/test_deserialization.py
@@ -28,7 +28,7 @@ def setUp(self):
self.deserialize = self.api_client.deserialize
def test_enum_test(self):
- """ deserialize Dict[str, EnumTest] """
+ """ deserialize dict[str, EnumTest] """
data = {
'enum_test': {
"enum_string": "UPPER",
@@ -40,7 +40,7 @@ def test_enum_test(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, EnumTest]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, EnumTest]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['enum_test'], petstore_api.EnumTest))
self.assertEqual(deserialized['enum_test'],
@@ -51,7 +51,7 @@ def test_enum_test(self):
outerEnum=petstore_api.OuterEnum.PLACED))
def test_deserialize_dict_str_pet(self):
- """ deserialize Dict[str, Pet] """
+ """ deserialize dict[str, Pet] """
data = {
'pet': {
"id": 0,
@@ -74,13 +74,13 @@ def test_deserialize_dict_str_pet(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, Pet]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, Pet]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['pet'], petstore_api.Pet))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_dog(self):
- """ deserialize Dict[str, Animal], use discriminator"""
+ """ deserialize dict[str, Animal], use discriminator"""
data = {
'dog': {
"id": 0,
@@ -91,19 +91,19 @@ def test_deserialize_dict_str_dog(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, Animal]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, Animal]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['dog'], petstore_api.Dog))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_int(self):
- """ deserialize Dict[str, int] """
+ """ deserialize dict[str, int] """
data = {
'integer': 1
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, int]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, int]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['integer'], int))
@@ -212,7 +212,7 @@ def test_deserialize_list_of_pet(self):
}]
response = json.dumps(data)
- deserialized = self.deserialize(response, "List[Pet]", 'application/json')
+ deserialized = self.deserialize(response, "list[Pet]", 'application/json')
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], petstore_api.Pet))
self.assertEqual(deserialized[0].id, 0)
@@ -221,7 +221,7 @@ def test_deserialize_list_of_pet(self):
self.assertEqual(deserialized[1].name, "doggie1")
def test_deserialize_nested_dict(self):
- """ deserialize Dict[str, Dict[str, int]] """
+ """ deserialize dict[str, dict[str, int]] """
data = {
"foo": {
"bar": 1
@@ -229,7 +229,7 @@ def test_deserialize_nested_dict(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, "Dict[str, Dict[str, int]]", 'application/json')
+ deserialized = self.deserialize(response, "dict[str, dict[str, int]]", 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized["foo"], dict))
self.assertTrue(isinstance(deserialized["foo"]["bar"], int))
@@ -239,7 +239,7 @@ def test_deserialize_nested_list(self):
data = [["foo"]]
response = json.dumps(data)
- deserialized = self.deserialize(response, "List[List[str]]", 'application/json')
+ deserialized = self.deserialize(response, "list[list[str]]", 'application/json')
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], list))
self.assertTrue(isinstance(deserialized[0][0], str))
@@ -311,18 +311,18 @@ def test_deserialize_content_type(self):
response = json.dumps({"a": "a"})
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/json')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/vnd.api+json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/vnd.api+json')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/json; charset=utf-8')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/json; charset=utf-8')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/vnd.api+json; charset=utf-8')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/vnd.api+json; charset=utf-8')
self.assertTrue(isinstance(deserialized, dict))
deserialized = self.deserialize(response, "str", 'text/plain')
@@ -331,7 +331,7 @@ def test_deserialize_content_type(self):
deserialized = self.deserialize(response, "str", 'text/csv')
self.assertTrue(isinstance(deserialized, str))
- deserialized = self.deserialize(response, "Dict[str, str]", 'APPLICATION/JSON')
+ deserialized = self.deserialize(response, "dict[str, str]", 'APPLICATION/JSON')
self.assertTrue(isinstance(deserialized, dict))
with self.assertRaises(petstore_api.ApiException) as cm:
@@ -341,8 +341,8 @@ def test_deserialize_content_type(self):
deserialized = self.deserialize(response, "str", 'text/n0t-exist!ng')
with self.assertRaises(petstore_api.ApiException) as cm:
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/jsonnnnn')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/jsonnnnn')
with self.assertRaises(petstore_api.ApiException) as cm:
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/<+json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/<+json')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/AdditionalPropertiesClass.md
index 5517244bc67f..c7f970aa0e3d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/AdditionalPropertiesClass.md
@@ -4,9 +4,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfModel.md
index 0b93fb437aba..b17b84d98a6c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
index 4bb70bf2786b..f83375e0e56c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfArrayOfNumberOnly.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfMapModel.md
index 23cbeb599569..afa11d7b5cf8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfMapModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfNumberOnly.md
index 395ad7f9f8bb..dadee092b04a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayOfNumberOnly.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayTest.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayTest.md
index 0b2fb30bff34..9740fca12b3e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ArrayTest.md
@@ -4,10 +4,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[float]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[float]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/CircularAllOfRef.md
index 3c6bc5fa6f7f..3843c1499261 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/CircularAllOfRef.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/EnumArrays.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/EnumArrays.md
index 4f4004c16724..b7ae39a6c536 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/EnumArrays.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FakeApi.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FakeApi.md
index 6aa84ef041f1..e9c8ce73d726 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FakeApi.md
@@ -662,7 +662,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = await api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -679,7 +679,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1137,7 +1137,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1181,7 +1181,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1414,7 +1414,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1429,7 +1429,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2118,7 +2118,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2133,7 +2133,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2377,13 +2377,13 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
await api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2397,13 +2397,13 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2452,7 +2452,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2467,7 +2467,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FileSchemaTestClass.md
index 16f4b7a29c20..150cc6ecbeeb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/FileSchemaTestClass.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/InputAllOf.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/InputAllOf.md
index 50e0f318e701..6af147e9babe 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/InputAllOf.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapOfArrayOfModel.md
index 912a72c77431..6c3d47e817d8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapOfArrayOfModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapTest.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapTest.md
index 37d65a59c8af..99a72d0c1b1d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MapTest.md
@@ -4,10 +4,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 53d7988588b0..bef7b7596fb9 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -6,7 +6,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **str** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MultiArrays.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MultiArrays.md
index 2b461769611c..5b255a0541d1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/MultiArrays.md
@@ -4,8 +4,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/NullableClass.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/NullableClass.md
index d6ca700c8877..ec2b80aa7c5a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/NullableClass.md
@@ -11,12 +11,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[object]** | | [optional]
-**array_items_nullable** | **List[object]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_items_nullable** | **Dict[str, object]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[object]** | | [optional]
+**array_items_nullable** | **list[object]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, object]** | | [optional]
+**object_items_nullable** | **dict[str, object]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ObjectWithDeprecatedFields.md
index 324130af8dd4..3876a4341a20 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ObjectWithDeprecatedFields.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Parent.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Parent.md
index de6fb2bf47a9..4799b5f79f06 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Parent.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ParentWithOptionalDict.md
index 817faeed32f4..c465512d584f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/ParentWithOptionalDict.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Pet.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Pet.md
index 4eedd9366ac6..47d5e3cb7654 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/Pet.md
@@ -7,8 +7,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PetApi.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PetApi.md
index e6817874690a..c2803328534b 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PetApi.md
@@ -226,7 +226,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -323,7 +323,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -340,11 +340,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -364,7 +364,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -461,7 +461,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -478,11 +478,11 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PropertyMap.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PropertyMap.md
index 2b727c644096..9ce33d05952b 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/PropertyMap.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/SecondCircularAllOfRef.md
index bcb8b5fe4539..0516305cbd24 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/SecondCircularAllOfRef.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/StoreApi.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/StoreApi.md
index 9d7a7b781701..4c378e0b7caf 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/StoreApi.md
@@ -76,7 +76,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -130,7 +130,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
index 784b34c29659..52e54b3114a8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
index 904c007e2072..1476ce6a46c7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UserApi.md b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UserApi.md
index 0bd69e33d903..d9055d19db60 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -122,7 +122,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -172,7 +172,7 @@ configuration = petstore_api.Configuration(
async with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -187,7 +187,7 @@ async with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/fake_api.py
index 7ee53259a5b9..88124c0f3440 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/fake_api.py
@@ -24,7 +24,7 @@
from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr, conbytes, confloat, conint, conlist, constr, validator
-from typing import Any, Dict, List, Optional, Union
+from typing import Any, Optional, Union
from petstore_api.models.api_response import ApiResponse
from petstore_api.models.client import Client
@@ -62,7 +62,7 @@ def __init__(self, api_client=None) -> None:
self.api_client = api_client
@validate_arguments
- async def fake_any_type_request_body(self, body : Optional[Dict[str, Any]] = None, **kwargs) -> None: # noqa: E501
+ async def fake_any_type_request_body(self, body : Optional[dict[str, Any]] = None, **kwargs) -> None: # noqa: E501
"""test any type request body # noqa: E501
@@ -84,7 +84,7 @@ async def fake_any_type_request_body(self, body : Optional[Dict[str, Any]] = Non
return await self.fake_any_type_request_body_with_http_info(body, **kwargs) # noqa: E501
@validate_arguments
- async def fake_any_type_request_body_with_http_info(self, body : Optional[Dict[str, Any]] = None, **kwargs) -> ApiResponse: # noqa: E501
+ async def fake_any_type_request_body_with_http_info(self, body : Optional[dict[str, Any]] = None, **kwargs) -> ApiResponse: # noqa: E501
"""test any type request body # noqa: E501
@@ -1086,7 +1086,7 @@ async def fake_property_enum_integer_serialize(self, outer_object_with_enum_prop
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1111,7 +1111,7 @@ async def fake_property_enum_integer_serialize_with_http_info(self, outer_object
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -2016,7 +2016,7 @@ async def fake_return_int_with_http_info(self, **kwargs) -> ApiResponse: # noqa
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def fake_return_list_of_objects(self, **kwargs) -> List[List[Tag]]: # noqa: E501
+ async def fake_return_list_of_objects(self, **kwargs) -> list[list[Tag]]: # noqa: E501
"""test returning list of objects # noqa: E501
@@ -2027,7 +2027,7 @@ async def fake_return_list_of_objects(self, **kwargs) -> List[List[Tag]]: # noq
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[List[Tag]]
+ :rtype: list[list[Tag]]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -2060,7 +2060,7 @@ async def fake_return_list_of_objects_with_http_info(self, **kwargs) -> ApiRespo
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[List[Tag]], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[list[Tag]], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -2110,7 +2110,7 @@ async def fake_return_list_of_objects_with_http_info(self, **kwargs) -> ApiRespo
_auth_settings = [] # noqa: E501
_response_types_map = {
- '200': "List[List[Tag]]",
+ '200': "list[list[Tag]]",
}
return await self.api_client.call_api(
@@ -2474,13 +2474,13 @@ async def fake_uuid_example_with_http_info(self, uuid_example : Annotated[Strict
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def test_additional_properties_reference(self, request_body : Annotated[Dict[str, Any], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ async def test_additional_properties_reference(self, request_body : Annotated[dict[str, Any], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test referenced additionalProperties # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2497,13 +2497,13 @@ async def test_additional_properties_reference(self, request_body : Annotated[Di
return await self.test_additional_properties_reference_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- async def test_additional_properties_reference_with_http_info(self, request_body : Annotated[Dict[str, Any], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ async def test_additional_properties_reference_with_http_info(self, request_body : Annotated[dict[str, Any], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test referenced additionalProperties # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -3864,13 +3864,13 @@ async def test_group_parameters_with_http_info(self, required_string_group : Ann
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def test_inline_additional_properties(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ async def test_inline_additional_properties(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test inline additionalProperties # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -3887,13 +3887,13 @@ async def test_inline_additional_properties(self, request_body : Annotated[Dict[
return await self.test_inline_additional_properties_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- async def test_inline_additional_properties_with_http_info(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ async def test_inline_additional_properties_with_http_info(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test inline additionalProperties # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -4370,25 +4370,25 @@ async def test_object_for_multipart_requests_with_http_info(self, marker : TestO
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[Dict[str, StrictStr]] = None, **kwargs) -> None: # noqa: E501
+ async def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[dict[str, StrictStr]] = None, **kwargs) -> None: # noqa: E501
"""test_query_parameter_collection_format # noqa: E501
To test the collection format in query parameters # noqa: E501
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -4405,25 +4405,25 @@ async def test_query_parameter_collection_format(self, pipe : conlist(StrictStr)
return await self.test_query_parameter_collection_format_with_http_info(pipe, ioutil, http, url, context, allow_empty, language, **kwargs) # noqa: E501
@validate_arguments
- async def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[Dict[str, StrictStr]] = None, **kwargs) -> ApiResponse: # noqa: E501
+ async def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[dict[str, StrictStr]] = None, **kwargs) -> ApiResponse: # noqa: E501
"""test_query_parameter_collection_format # noqa: E501
To test the collection format in query parameters # noqa: E501
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -4541,13 +4541,13 @@ async def test_query_parameter_collection_format_with_http_info(self, pipe : con
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def test_string_map_reference(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ async def test_string_map_reference(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test referenced string map # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -4564,13 +4564,13 @@ async def test_string_map_reference(self, request_body : Annotated[Dict[str, Str
return await self.test_string_map_reference_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- async def test_string_map_reference_with_http_info(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ async def test_string_map_reference_with_http_info(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test referenced string map # noqa: E501
# noqa: E501
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/pet_api.py
index cb4e3ee8896e..85a2de63ba1a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/pet_api.py
@@ -22,7 +22,7 @@
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, conlist, validator
-from typing import List, Optional, Union
+from typing import Optional, Union
from petstore_api.models.api_response import ApiResponse
from petstore_api.models.pet import Pet
@@ -299,13 +299,13 @@ async def delete_pet_with_http_info(self, pet_id : Annotated[StrictInt, Field(..
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(..., description="Status values that need to be considered for filter")], **kwargs) -> List[Pet]: # noqa: E501
+ async def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(..., description="Status values that need to be considered for filter")], **kwargs) -> list[Pet]: # noqa: E501
"""Finds Pets by status # noqa: E501
Multiple status values can be provided with comma separated strings # noqa: E501
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -313,7 +313,7 @@ async def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -328,7 +328,7 @@ async def find_pets_by_status_with_http_info(self, status : Annotated[conlist(St
Multiple status values can be provided with comma separated strings # noqa: E501
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -349,7 +349,7 @@ async def find_pets_by_status_with_http_info(self, status : Annotated[conlist(St
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[Pet], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[Pet], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -404,7 +404,7 @@ async def find_pets_by_status_with_http_info(self, status : Annotated[conlist(St
_auth_settings = ['petstore_auth', 'http_signature_test'] # noqa: E501
_response_types_map = {
- '200': "List[Pet]",
+ '200': "list[Pet]",
'400': None,
}
@@ -425,13 +425,13 @@ async def find_pets_by_status_with_http_info(self, status : Annotated[conlist(St
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=True), Field(..., description="Tags to filter by")], **kwargs) -> List[Pet]: # noqa: E501
+ async def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=True), Field(..., description="Tags to filter by")], **kwargs) -> list[Pet]: # noqa: E501
"""(Deprecated) Finds Pets by tags # noqa: E501
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -439,7 +439,7 @@ async def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_ite
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -454,7 +454,7 @@ async def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(Strict
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -475,7 +475,7 @@ async def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(Strict
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[Pet], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[Pet], status_code(int), headers(HTTPHeaderDict))
"""
warnings.warn("GET /pet/findByTags is deprecated.", DeprecationWarning)
@@ -532,7 +532,7 @@ async def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(Strict
_auth_settings = ['petstore_auth', 'http_signature_test'] # noqa: E501
_response_types_map = {
- '200': "List[Pet]",
+ '200': "list[Pet]",
'400': None,
}
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/store_api.py
index a904a1f2c572..239b80f8812e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/store_api.py
@@ -22,8 +22,6 @@
from typing_extensions import Annotated
from pydantic import Field, StrictStr, conint
-from typing import Dict
-
from petstore_api.models.order import Order
from petstore_api.api_client import ApiClient
@@ -165,7 +163,7 @@ async def delete_order_with_http_info(self, order_id : Annotated[StrictStr, Fiel
_request_auth=_params.get('_request_auth'))
@validate_arguments
- async def get_inventory(self, **kwargs) -> Dict[str, int]: # noqa: E501
+ async def get_inventory(self, **kwargs) -> dict[str, int]: # noqa: E501
"""Returns pet inventories by status # noqa: E501
Returns a map of status codes to quantities # noqa: E501
@@ -177,7 +175,7 @@ async def get_inventory(self, **kwargs) -> Dict[str, int]: # noqa: E501
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: Dict[str, int]
+ :rtype: dict[str, int]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -211,7 +209,7 @@ async def get_inventory_with_http_info(self, **kwargs) -> ApiResponse: # noqa:
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(Dict[str, int], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(dict[str, int], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -261,7 +259,7 @@ async def get_inventory_with_http_info(self, **kwargs) -> ApiResponse: # noqa:
_auth_settings = ['api_key'] # noqa: E501
_response_types_map = {
- '200': "Dict[str, int]",
+ '200': "dict[str, int]",
}
return await self.api_client.call_api(
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/user_api.py
index c26a41c0b048..09cc6877d5fd 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api/user_api.py
@@ -192,7 +192,7 @@ async def create_users_with_array_input(self, user : Annotated[conlist(User), Fi
# noqa: E501
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -215,7 +215,7 @@ async def create_users_with_array_input_with_http_info(self, user : Annotated[co
# noqa: E501
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
@@ -317,7 +317,7 @@ async def create_users_with_list_input(self, user : Annotated[conlist(User), Fie
# noqa: E501
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request.
If one number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -340,7 +340,7 @@ async def create_users_with_list_input_with_http_info(self, user : Annotated[con
# noqa: E501
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _preload_content: if False, the ApiResponse.data will
be set to none and raw_data will store the
HTTP response body without reading/decoding.
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_client.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_client.py
index 3581aae40035..cba9aba19069 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_client.py
@@ -318,13 +318,13 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- sub_kls = re.match(r'List\[(.*)]', klass).group(1)
+ if klass.startswith('list['):
+ sub_kls = re.match(r'list\[(.*)]', klass).group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- sub_kls = re.match(r'Dict\[([^,]*), (.*)]', klass).group(2)
+ if klass.startswith('dict['):
+ sub_kls = re.match(r'dict\[([^,]*), (.*)]', klass).group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_response.py
index a0b62b95246c..0ce9c905789f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/api_response.py
@@ -1,7 +1,7 @@
"""API response object."""
from __future__ import annotations
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictInt, StrictStr
class ApiResponse:
@@ -10,7 +10,7 @@ class ApiResponse:
"""
status_code: Optional[StrictInt] = Field(None, description="HTTP status code")
- headers: Optional[Dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
+ headers: Optional[dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
data: Optional[Any] = Field(None, description="Deserialized data given the data type")
raw_data: Optional[Any] = Field(None, description="Raw data (HTTP response body)")
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_any_type.py
index 0441dfd99e92..b04ba0846afb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_any_type.py
@@ -26,7 +26,7 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py
index ed5cfb508668..273539959bd9 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel, StrictStr
from petstore_api.models.pet import Pet
@@ -26,9 +26,9 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
"""
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
__properties = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_object.py
index cff0e89b0568..f5558870434a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_object.py
@@ -26,7 +26,7 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_with_description_only.py
index 17d6c461ed1b..a9b570406935 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_with_description_only.py
@@ -26,7 +26,7 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_color.py
index d1ed38dc9b1b..af94b4c1e2c6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_color.py
@@ -18,29 +18,29 @@
import pprint
import re # noqa: F401
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, conlist, constr, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
+ # data type: list[int]
anyof_schema_1_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=3, min_items=3)] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
+ # data type: list[int]
anyof_schema_2_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=4, min_items=4)] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[constr(strict=True, max_length=7, min_length=7)] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Union[List[int], str]
+ actual_instance: Union[list[int], str]
else:
actual_instance: Any
- any_of_schemas: List[str] = Field(ANYOFCOLOR_ANY_OF_SCHEMAS, const=True)
+ any_of_schemas: list[str] = Field(ANYOFCOLOR_ANY_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
@@ -59,13 +59,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -79,7 +79,7 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@@ -92,7 +92,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
"""Returns the object represented by the json string"""
instance = AnyOfColor.construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -101,7 +101,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -122,7 +122,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_pig.py
index 018d892467b6..a2566b6b3fb3 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/any_of_pig.py
@@ -22,7 +22,7 @@
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
ANYOFPIG_ANY_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Union[BasquePig, DanishPig]
else:
actual_instance: Any
- any_of_schemas: List[str] = Field(ANYOFPIG_ANY_OF_SCHEMAS, const=True)
+ any_of_schemas: list[str] = Field(ANYOFPIG_ANY_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py
index 6f67b220ccf1..19b7c071b5be 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, conlist
from petstore_api.models.tag import Tag
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py
index 3c160bb53034..e2f5d6bef612 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, conlist
class ArrayOfArrayOfNumberOnly(BaseModel):
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_map_model.py
index 9c8cd740b509..729ef5fbf3a2 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_map_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, List, Optional
+from typing import Optional
from pydantic import BaseModel, conlist
from petstore_api.models.tag import Tag
@@ -26,7 +26,7 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
"""
- array_of_map_property: Optional[conlist(Dict[str, Tag])] = None
+ array_of_map_property: Optional[conlist(dict[str, Tag])] = None
__properties = ["array_of_map_property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py
index ce172811448a..65c440caef96 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, conlist
class ArrayOfNumberOnly(BaseModel):
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py
index 206b34dc4021..bb1df0cb494e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, StrictInt, StrictStr, conlist
from petstore_api.models.read_only_first import ReadOnlyFirst
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py
index 9177641a136f..ecd59fb26683 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class CircularAllOfRef(BaseModel):
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/color.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/color.py
index 8500a75d8325..3fd74c2c8e08 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/color.py
@@ -18,28 +18,28 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, conlist, constr, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
+ # data type: list[int]
oneof_schema_1_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=3, min_items=3)] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
+ # data type: list[int]
oneof_schema_2_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=4, min_items=4)] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[constr(strict=True, max_length=7, min_length=7)] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Union[List[int], str]
+ actual_instance: Union[list[int], str]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(COLOR_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(COLOR_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
@@ -62,13 +62,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -82,10 +82,10 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@@ -103,7 +103,7 @@ def from_json(cls, json_str: str) -> Color:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -112,7 +112,7 @@ def from_json(cls, json_str: str) -> Color:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -133,10 +133,10 @@ def from_json(cls, json_str: str) -> Color:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py
index 05d532614fff..d13875e20f36 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, StrictStr, conlist, validator
class EnumArrays(BaseModel):
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py
index 32058bd16fa0..acd044fc7dbb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, conlist
from petstore_api.models.file import File
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py
index a455a5bb59dd..135f5145c4a2 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py
@@ -18,14 +18,14 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field
class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
"""
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
__properties = ["aProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py
index d9e6f42ae4f3..270652ee77f5 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel
from petstore_api.models.tag import Tag
@@ -26,7 +26,7 @@ class InputAllOf(BaseModel):
"""
InputAllOf
"""
- some_data: Optional[Dict[str, Tag]] = None
+ some_data: Optional[dict[str, Tag]] = None
__properties = ["some_data"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/int_or_string.py
index 5d5de47e305a..92673590bfd4 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/int_or_string.py
@@ -18,9 +18,9 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -37,7 +37,7 @@ class IntOrString(BaseModel):
actual_instance: Union[int, str]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(INTORSTRING_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(INTORSTRING_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py
index b4c4ba94b51e..f7f1913ec4d0 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.tag import Tag
@@ -26,7 +26,7 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
"""
- shop_id_to_org_online_lip_map: Optional[Dict[str, conlist(Tag)]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ shop_id_to_org_online_lip_map: Optional[dict[str, conlist(Tag)]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
__properties = ["shopIdToOrgOnlineLipMap"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py
index ce853d3d77b1..c5b46162dfa8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py
@@ -18,17 +18,17 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel, StrictBool, StrictStr, validator
class MapTest(BaseModel):
"""
MapTest
"""
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
__properties = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@validator('map_of_enum_string')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
index 622839ee0492..4bc1307f911b 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -18,7 +18,7 @@
import json
from datetime import datetime
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr
from petstore_api.models.animal import Animal
@@ -28,7 +28,7 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
"""
uuid: Optional[StrictStr] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
+ map: Optional[dict[str, Animal]] = None
__properties = ["uuid", "dateTime", "map"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py
index ce0acf8c8fda..5110c75719e7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_class.py
index f26aac9ff07d..db06a40c66f6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_class.py
@@ -18,7 +18,7 @@
import json
from datetime import date, datetime
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictBool, StrictInt, StrictStr, conlist
class NullableClass(BaseModel):
@@ -32,13 +32,13 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[conlist(Dict[str, Any])] = None
- array_and_items_nullable_prop: Optional[conlist(Dict[str, Any])] = None
- array_items_nullable: Optional[conlist(Dict[str, Any])] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_items_nullable: Optional[Dict[str, Dict[str, Any]]] = None
- additional_properties: Dict[str, Any] = {}
+ array_nullable_prop: Optional[conlist(dict[str, Any])] = None
+ array_and_items_nullable_prop: Optional[conlist(dict[str, Any])] = None
+ array_items_nullable: Optional[conlist(dict[str, Any])] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_items_nullable: Optional[dict[str, dict[str, Any]]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py
index e976e40738bd..00fd5084920b 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, conlist
from petstore_api.models.deprecated_object import DeprecatedObject
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py
index 90c7f90d2d61..2eee8f2695ce 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel, Field
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
@@ -26,7 +26,7 @@ class Parent(BaseModel):
"""
Parent
"""
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
__properties = ["optionalDict"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py
index 2f2010cd4478..8084da4b1822 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel, Field
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
@@ -26,7 +26,7 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
"""
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
__properties = ["optionalDict"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py
index 112508adac5a..2f76f5e6a336 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr, conlist, validator
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pig.py
index 1cb002bf6f7d..8bdc8dcb9762 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pig.py
@@ -18,11 +18,11 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -39,7 +39,7 @@ class Pig(BaseModel):
actual_instance: Union[BasquePig, DanishPig]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(PIG_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(PIG_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py
index ccd88f12125e..76ed9ca0fc00 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, Optional
+from typing import Optional
from pydantic import BaseModel
from petstore_api.models.tag import Tag
@@ -26,7 +26,7 @@ class PropertyMap(BaseModel):
"""
PropertyMap
"""
- some_data: Optional[Dict[str, Tag]] = None
+ some_data: Optional[dict[str, Tag]] = None
__properties = ["some_data"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py
index 2d000534484d..85405463fb49 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class SecondCircularAllOfRef(BaseModel):
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task_activity.py
index 70553f1ef202..f671aff56754 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task_activity.py
@@ -18,12 +18,12 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -42,7 +42,7 @@ class TaskActivity(BaseModel):
actual_instance: Union[Bathing, Feeding, PoopCleaning]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(TASKACTIVITY_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(TASKACTIVITY_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 41b768501e8a..d91917bdea30 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -26,7 +26,7 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
"""
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["someProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index dbd8dd518635..6bbdb4e46eed 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,7 +18,7 @@
import json
-from typing import Dict, List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.creature_info import CreatureInfo
@@ -26,7 +26,7 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
"""
- dict_property: Optional[Dict[str, conlist(CreatureInfo)]] = Field(default=None, alias="dictProperty")
+ dict_property: Optional[dict[str, conlist(CreatureInfo)]] = Field(default=None, alias="dictProperty")
__properties = ["dictProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index af559dfa890c..6314dc5a5739 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,14 +18,14 @@
import json
-from typing import Dict, List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
"""
- dict_property: Optional[Dict[str, conlist(StrictStr)]] = Field(default=None, alias="dictProperty")
+ dict_property: Optional[dict[str, conlist(StrictStr)]] = Field(default=None, alias="dictProperty")
__properties = ["dictProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/tests/test_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/tests/test_model.py
index e81fb1cd3601..7bfd17762a0a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/tests/test_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/tests/test_model.py
@@ -178,7 +178,7 @@ def test_list(self):
self.assertTrue(False) # this line shouldn't execute
except ValueError as e:
#error_message = (
- # "1 validation error for List\n"
+ # "1 validation error for list\n"
# "123-list\n"
# " str type expected (type=type_error.str)\n")
self.assertTrue("str type expected" in str(e))
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/AdditionalPropertiesClass.md
index 5517244bc67f..c7f970aa0e3d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/AdditionalPropertiesClass.md
@@ -4,9 +4,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfModel.md
index 0b93fb437aba..b17b84d98a6c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfNumberOnly.md
index 4bb70bf2786b..f83375e0e56c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfArrayOfNumberOnly.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfMapModel.md
index 23cbeb599569..afa11d7b5cf8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfMapModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfNumberOnly.md
index 395ad7f9f8bb..dadee092b04a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayOfNumberOnly.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayTest.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayTest.md
index 0b2fb30bff34..9740fca12b3e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ArrayTest.md
@@ -4,10 +4,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[float]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[float]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/CircularAllOfRef.md
index 3c6bc5fa6f7f..3843c1499261 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/CircularAllOfRef.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/EnumArrays.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/EnumArrays.md
index 4f4004c16724..b7ae39a6c536 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/EnumArrays.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/FakeApi.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/FakeApi.md
index 6935c8587a23..e25559082b71 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/FakeApi.md
@@ -662,7 +662,7 @@ with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -679,7 +679,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1137,7 +1137,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1181,7 +1181,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1414,7 +1414,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1429,7 +1429,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2118,7 +2118,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2133,7 +2133,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2377,13 +2377,13 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2397,13 +2397,13 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2452,7 +2452,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2467,7 +2467,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/FileSchemaTestClass.md
index 16f4b7a29c20..150cc6ecbeeb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/FileSchemaTestClass.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/InputAllOf.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/InputAllOf.md
index 50e0f318e701..6af147e9babe 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/InputAllOf.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapOfArrayOfModel.md
index 912a72c77431..6c3d47e817d8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapOfArrayOfModel.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapTest.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapTest.md
index 37d65a59c8af..99a72d0c1b1d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MapTest.md
@@ -4,10 +4,10 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 53d7988588b0..bef7b7596fb9 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -6,7 +6,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **str** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MultiArrays.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MultiArrays.md
index 2b461769611c..5b255a0541d1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/MultiArrays.md
@@ -4,8 +4,8 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/NullableClass.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/NullableClass.md
index d6ca700c8877..ec2b80aa7c5a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/NullableClass.md
@@ -11,12 +11,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[object]** | | [optional]
-**array_items_nullable** | **List[object]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_items_nullable** | **Dict[str, object]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[object]** | | [optional]
+**array_items_nullable** | **list[object]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, object]** | | [optional]
+**object_items_nullable** | **dict[str, object]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ObjectWithDeprecatedFields.md
index 324130af8dd4..3876a4341a20 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ObjectWithDeprecatedFields.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/Parent.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/Parent.md
index de6fb2bf47a9..4799b5f79f06 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/Parent.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ParentWithOptionalDict.md
index 817faeed32f4..c465512d584f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/ParentWithOptionalDict.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/Pet.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/Pet.md
index 4eedd9366ac6..47d5e3cb7654 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/Pet.md
@@ -7,8 +7,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/PetApi.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/PetApi.md
index 8a0202f37531..ea215c30e1de 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/PetApi.md
@@ -226,7 +226,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -323,7 +323,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -340,11 +340,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -364,7 +364,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -461,7 +461,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -478,11 +478,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/PropertyMap.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/PropertyMap.md
index 2b727c644096..9ce33d05952b 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/PropertyMap.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/SecondCircularAllOfRef.md
index bcb8b5fe4539..0516305cbd24 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/SecondCircularAllOfRef.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/StoreApi.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/StoreApi.md
index 9a4c0ec8c002..f7532150640a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/StoreApi.md
@@ -76,7 +76,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -130,7 +130,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalModelListProperties.md
index 784b34c29659..52e54b3114a8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalStringListProperties.md
index 904c007e2072..1476ce6a46c7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UserApi.md b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UserApi.md
index 810e75e12717..718e12a42c49 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -122,7 +122,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -172,7 +172,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -187,7 +187,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/fake_api.py
index 62ef06ed6b0e..05ca7629b733 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/fake_api.py
@@ -23,7 +23,7 @@
from pydantic import Field, StrictBool, StrictBytes, StrictFloat, StrictInt, StrictStr, conbytes, confloat, conint, conlist, constr, validator
-from typing import Any, Dict, List, Optional, Union
+from typing import Any, Optional, Union
from petstore_api.models.api_response import ApiResponse
from petstore_api.models.client import Client
@@ -61,7 +61,7 @@ def __init__(self, api_client=None) -> None:
self.api_client = api_client
@validate_arguments
- def fake_any_type_request_body(self, body : Optional[Dict[str, Any]] = None, **kwargs) -> None: # noqa: E501
+ def fake_any_type_request_body(self, body : Optional[dict[str, Any]] = None, **kwargs) -> None: # noqa: E501
"""test any type request body # noqa: E501
This method makes a synchronous HTTP request by default. To make an
@@ -90,7 +90,7 @@ def fake_any_type_request_body(self, body : Optional[Dict[str, Any]] = None, **k
return self.fake_any_type_request_body_with_http_info(body, **kwargs) # noqa: E501
@validate_arguments
- def fake_any_type_request_body_with_http_info(self, body : Optional[Dict[str, Any]] = None, **kwargs) -> ApiResponse: # noqa: E501
+ def fake_any_type_request_body_with_http_info(self, body : Optional[dict[str, Any]] = None, **kwargs) -> ApiResponse: # noqa: E501
"""test any type request body # noqa: E501
This method makes a synchronous HTTP request by default. To make an
@@ -1218,7 +1218,7 @@ def fake_property_enum_integer_serialize(self, outer_object_with_enum_property :
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -1250,7 +1250,7 @@ def fake_property_enum_integer_serialize_with_http_info(self, outer_object_with_
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -2271,7 +2271,7 @@ def fake_return_int_with_http_info(self, **kwargs) -> ApiResponse: # noqa: E501
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def fake_return_list_of_objects(self, **kwargs) -> List[List[Tag]]: # noqa: E501
+ def fake_return_list_of_objects(self, **kwargs) -> list[list[Tag]]: # noqa: E501
"""test returning list of objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
@@ -2289,7 +2289,7 @@ def fake_return_list_of_objects(self, **kwargs) -> List[List[Tag]]: # noqa: E50
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[List[Tag]]
+ :rtype: list[list[Tag]]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -2329,7 +2329,7 @@ def fake_return_list_of_objects_with_http_info(self, **kwargs) -> ApiResponse:
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[List[Tag]], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[list[Tag]], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -2380,7 +2380,7 @@ def fake_return_list_of_objects_with_http_info(self, **kwargs) -> ApiResponse:
_auth_settings = [] # noqa: E501
_response_types_map = {
- '200': "List[List[Tag]]",
+ '200': "list[list[Tag]]",
}
return self.api_client.call_api(
@@ -2793,7 +2793,7 @@ def fake_uuid_example_with_http_info(self, uuid_example : Annotated[StrictStr, F
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def test_additional_properties_reference(self, request_body : Annotated[Dict[str, Any], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ def test_additional_properties_reference(self, request_body : Annotated[dict[str, Any], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test referenced additionalProperties # noqa: E501
# noqa: E501
@@ -2804,7 +2804,7 @@ def test_additional_properties_reference(self, request_body : Annotated[Dict[str
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -2823,7 +2823,7 @@ def test_additional_properties_reference(self, request_body : Annotated[Dict[str
return self.test_additional_properties_reference_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- def test_additional_properties_reference_with_http_info(self, request_body : Annotated[Dict[str, Any], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ def test_additional_properties_reference_with_http_info(self, request_body : Annotated[dict[str, Any], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test referenced additionalProperties # noqa: E501
# noqa: E501
@@ -2834,7 +2834,7 @@ def test_additional_properties_reference_with_http_info(self, request_body : Ann
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -4343,7 +4343,7 @@ def test_group_parameters_with_http_info(self, required_string_group : Annotated
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def test_inline_additional_properties(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ def test_inline_additional_properties(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test inline additionalProperties # noqa: E501
# noqa: E501
@@ -4354,7 +4354,7 @@ def test_inline_additional_properties(self, request_body : Annotated[Dict[str, S
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -4373,7 +4373,7 @@ def test_inline_additional_properties(self, request_body : Annotated[Dict[str, S
return self.test_inline_additional_properties_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- def test_inline_additional_properties_with_http_info(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ def test_inline_additional_properties_with_http_info(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test inline additionalProperties # noqa: E501
# noqa: E501
@@ -4384,7 +4384,7 @@ def test_inline_additional_properties_with_http_info(self, request_body : Annota
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -4913,7 +4913,7 @@ def test_object_for_multipart_requests_with_http_info(self, marker : TestObjectF
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[Dict[str, StrictStr]] = None, **kwargs) -> None: # noqa: E501
+ def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[dict[str, StrictStr]] = None, **kwargs) -> None: # noqa: E501
"""test_query_parameter_collection_format # noqa: E501
To test the collection format in query parameters # noqa: E501
@@ -4924,19 +4924,19 @@ def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), iout
>>> result = thread.get()
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -4955,7 +4955,7 @@ def test_query_parameter_collection_format(self, pipe : conlist(StrictStr), iout
return self.test_query_parameter_collection_format_with_http_info(pipe, ioutil, http, url, context, allow_empty, language, **kwargs) # noqa: E501
@validate_arguments
- def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[Dict[str, StrictStr]] = None, **kwargs) -> ApiResponse: # noqa: E501
+ def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(StrictStr), ioutil : conlist(StrictStr), http : conlist(StrictStr), url : conlist(StrictStr), context : conlist(StrictStr), allow_empty : StrictStr, language : Optional[dict[str, StrictStr]] = None, **kwargs) -> ApiResponse: # noqa: E501
"""test_query_parameter_collection_format # noqa: E501
To test the collection format in query parameters # noqa: E501
@@ -4966,19 +4966,19 @@ def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(S
>>> result = thread.get()
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -5100,7 +5100,7 @@ def test_query_parameter_collection_format_with_http_info(self, pipe : conlist(S
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def test_string_map_reference(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
+ def test_string_map_reference(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> None: # noqa: E501
"""test referenced string map # noqa: E501
# noqa: E501
@@ -5111,7 +5111,7 @@ def test_string_map_reference(self, request_body : Annotated[Dict[str, StrictStr
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -5130,7 +5130,7 @@ def test_string_map_reference(self, request_body : Annotated[Dict[str, StrictStr
return self.test_string_map_reference_with_http_info(request_body, **kwargs) # noqa: E501
@validate_arguments
- def test_string_map_reference_with_http_info(self, request_body : Annotated[Dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
+ def test_string_map_reference_with_http_info(self, request_body : Annotated[dict[str, StrictStr], Field(..., description="request body")], **kwargs) -> ApiResponse: # noqa: E501
"""test referenced string map # noqa: E501
# noqa: E501
@@ -5141,7 +5141,7 @@ def test_string_map_reference_with_http_info(self, request_body : Annotated[Dict
>>> result = thread.get()
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/pet_api.py
index 44df5ee26605..8adfa6df437c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/pet_api.py
@@ -21,7 +21,7 @@
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, conlist, validator
-from typing import List, Optional, Union
+from typing import Optional, Union
from petstore_api.models.api_response import ApiResponse
from petstore_api.models.pet import Pet
@@ -330,7 +330,7 @@ def delete_pet_with_http_info(self, pet_id : Annotated[StrictInt, Field(..., des
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(..., description="Status values that need to be considered for filter")], **kwargs) -> List[Pet]: # noqa: E501
+ def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(..., description="Status values that need to be considered for filter")], **kwargs) -> list[Pet]: # noqa: E501
"""Finds Pets by status # noqa: E501
Multiple status values can be provided with comma separated strings # noqa: E501
@@ -341,7 +341,7 @@ def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(...,
>>> result = thread.get()
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -351,7 +351,7 @@ def find_pets_by_status(self, status : Annotated[conlist(StrictStr), Field(...,
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -371,7 +371,7 @@ def find_pets_by_status_with_http_info(self, status : Annotated[conlist(StrictSt
>>> result = thread.get()
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -394,7 +394,7 @@ def find_pets_by_status_with_http_info(self, status : Annotated[conlist(StrictSt
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[Pet], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[Pet], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -450,7 +450,7 @@ def find_pets_by_status_with_http_info(self, status : Annotated[conlist(StrictSt
_auth_settings = ['petstore_auth', 'http_signature_test'] # noqa: E501
_response_types_map = {
- '200': "List[Pet]",
+ '200': "list[Pet]",
'400': None,
}
@@ -472,7 +472,7 @@ def find_pets_by_status_with_http_info(self, status : Annotated[conlist(StrictSt
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=True), Field(..., description="Tags to filter by")], **kwargs) -> List[Pet]: # noqa: E501
+ def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=True), Field(..., description="Tags to filter by")], **kwargs) -> list[Pet]: # noqa: E501
"""(Deprecated) Finds Pets by tags # noqa: E501
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
@@ -483,7 +483,7 @@ def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=Tru
>>> result = thread.get()
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -493,7 +493,7 @@ def find_pets_by_tags(self, tags : Annotated[conlist(StrictStr, unique_items=Tru
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -513,7 +513,7 @@ def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(StrictStr, u
>>> result = thread.get()
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -536,7 +536,7 @@ def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(StrictStr, u
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(List[Pet], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(list[Pet], status_code(int), headers(HTTPHeaderDict))
"""
warnings.warn("GET /pet/findByTags is deprecated.", DeprecationWarning)
@@ -594,7 +594,7 @@ def find_pets_by_tags_with_http_info(self, tags : Annotated[conlist(StrictStr, u
_auth_settings = ['petstore_auth', 'http_signature_test'] # noqa: E501
_response_types_map = {
- '200': "List[Pet]",
+ '200': "list[Pet]",
'400': None,
}
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/store_api.py
index ad1fc048da50..28de94a68039 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/store_api.py
@@ -21,8 +21,6 @@
from typing_extensions import Annotated
from pydantic import Field, StrictStr, conint
-from typing import Dict
-
from petstore_api.models.order import Order
from petstore_api.api_client import ApiClient
@@ -180,7 +178,7 @@ def delete_order_with_http_info(self, order_id : Annotated[StrictStr, Field(...,
_request_auth=_params.get('_request_auth'))
@validate_arguments
- def get_inventory(self, **kwargs) -> Dict[str, int]: # noqa: E501
+ def get_inventory(self, **kwargs) -> dict[str, int]: # noqa: E501
"""Returns pet inventories by status # noqa: E501
Returns a map of status codes to quantities # noqa: E501
@@ -199,7 +197,7 @@ def get_inventory(self, **kwargs) -> Dict[str, int]: # noqa: E501
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: Dict[str, int]
+ :rtype: dict[str, int]
"""
kwargs['_return_http_data_only'] = True
if '_preload_content' in kwargs:
@@ -240,7 +238,7 @@ def get_inventory_with_http_info(self, **kwargs) -> ApiResponse: # noqa: E501
:return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
- :rtype: tuple(Dict[str, int], status_code(int), headers(HTTPHeaderDict))
+ :rtype: tuple(dict[str, int], status_code(int), headers(HTTPHeaderDict))
"""
_params = locals()
@@ -291,7 +289,7 @@ def get_inventory_with_http_info(self, **kwargs) -> ApiResponse: # noqa: E501
_auth_settings = ['api_key'] # noqa: E501
_response_types_map = {
- '200': "Dict[str, int]",
+ '200': "dict[str, int]",
}
return self.api_client.call_api(
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/user_api.py
index 0f9c0458d742..3fe35da97b92 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api/user_api.py
@@ -212,7 +212,7 @@ def create_users_with_array_input(self, user : Annotated[conlist(User), Field(..
>>> result = thread.get()
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -242,7 +242,7 @@ def create_users_with_array_input_with_http_info(self, user : Annotated[conlist(
>>> result = thread.get()
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
@@ -353,7 +353,7 @@ def create_users_with_list_input(self, user : Annotated[conlist(User), Field(...
>>> result = thread.get()
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _request_timeout: timeout setting for this request.
@@ -383,7 +383,7 @@ def create_users_with_list_input_with_http_info(self, user : Annotated[conlist(U
>>> result = thread.get()
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param async_req: Whether to execute the request asynchronously.
:type async_req: bool, optional
:param _preload_content: if False, the ApiResponse.data will
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_client.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_client.py
index 151d023104e7..781665bea29f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_client.py
@@ -337,13 +337,13 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- sub_kls = re.match(r'List\[(.*)]', klass).group(1)
+ if klass.startswith('list['):
+ sub_kls = re.match(r'list\[(.*)]', klass).group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- sub_kls = re.match(r'Dict\[([^,]*), (.*)]', klass).group(2)
+ if klass.startswith('dict['):
+ sub_kls = re.match(r'dict\[([^,]*), (.*)]', klass).group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_response.py
index a0b62b95246c..0ce9c905789f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/api_response.py
@@ -1,7 +1,7 @@
"""API response object."""
from __future__ import annotations
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictInt, StrictStr
class ApiResponse:
@@ -10,7 +10,7 @@ class ApiResponse:
"""
status_code: Optional[StrictInt] = Field(None, description="HTTP status code")
- headers: Optional[Dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
+ headers: Optional[dict[StrictStr, StrictStr]] = Field(None, description="HTTP headers")
data: Optional[Any] = Field(None, description="Deserialized data given the data type")
raw_data: Optional[Any] = Field(None, description="Raw data (HTTP response body)")
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_any_type.py
index a0f5848057e7..b73a3e292137 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_any_type.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class AdditionalPropertiesAnyType(BaseModel):
@@ -26,7 +26,7 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_class.py
index 5bd541132b11..77a195d11b54 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_class.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
from petstore_api.models.pet import Pet
@@ -26,10 +26,10 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
"""
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
- additional_properties: Dict[str, Any] = {}
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_object.py
index 022aa9c286a1..9a124b5f1cdd 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_object.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class AdditionalPropertiesObject(BaseModel):
@@ -26,7 +26,7 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_with_description_only.py
index ab7281d0dc4d..3a1db1fbc334 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/additional_properties_with_description_only.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class AdditionalPropertiesWithDescriptionOnly(BaseModel):
@@ -26,7 +26,7 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_super_model.py
index 77ab6c369b74..60b4c837a606 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_super_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_super_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class AllOfSuperModel(BaseModel):
@@ -26,7 +26,7 @@ class AllOfSuperModel(BaseModel):
AllOfSuperModel
"""
name: Optional[StrictStr] = Field(default=None, alias="_name")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_with_single_ref.py
index 802db7ad765a..e1c3553aa28d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_with_single_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/all_of_with_single_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
from petstore_api.models.single_ref_type import SingleRefType
@@ -28,7 +28,7 @@ class AllOfWithSingleRef(BaseModel):
"""
username: Optional[StrictStr] = None
single_ref_type: Optional[SingleRefType] = Field(default=None, alias="SingleRefType")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["username", "SingleRefType"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/animal.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/animal.py
index fe2f38d3c89e..989830360bff 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/animal.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/animal.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional, Union
+from typing import Any, Optional, Union
from pydantic import BaseModel, Field, StrictStr
from typing import TYPE_CHECKING
@@ -33,7 +33,7 @@ class Animal(BaseModel):
"""
class_name: StrictStr = Field(default=..., alias="className")
color: Optional[StrictStr] = 'red'
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["className", "color"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_color.py
index d1ed38dc9b1b..af94b4c1e2c6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_color.py
@@ -18,29 +18,29 @@
import pprint
import re # noqa: F401
-from typing import List, Optional
+from typing import Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, conlist, constr, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
+ # data type: list[int]
anyof_schema_1_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=3, min_items=3)] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
+ # data type: list[int]
anyof_schema_2_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=4, min_items=4)] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[constr(strict=True, max_length=7, min_length=7)] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Union[List[int], str]
+ actual_instance: Union[list[int], str]
else:
actual_instance: Any
- any_of_schemas: List[str] = Field(ANYOFCOLOR_ANY_OF_SCHEMAS, const=True)
+ any_of_schemas: list[str] = Field(ANYOFCOLOR_ANY_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
@@ -59,13 +59,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -79,7 +79,7 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@@ -92,7 +92,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
"""Returns the object represented by the json string"""
instance = AnyOfColor.construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -101,7 +101,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -122,7 +122,7 @@ def from_json(cls, json_str: str) -> AnyOfColor:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_pig.py
index 018d892467b6..a2566b6b3fb3 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/any_of_pig.py
@@ -22,7 +22,7 @@
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
ANYOFPIG_ANY_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Union[BasquePig, DanishPig]
else:
actual_instance: Any
- any_of_schemas: List[str] = Field(ANYOFPIG_ANY_OF_SCHEMAS, const=True)
+ any_of_schemas: list[str] = Field(ANYOFPIG_ANY_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/api_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/api_response.py
index 6224b7b9564d..1302c6c21e7e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/api_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/api_response.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictInt, StrictStr
class ApiResponse(BaseModel):
@@ -28,7 +28,7 @@ class ApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["code", "type", "message"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_model.py
index 0f444a85a296..cbff5e1940dd 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, conlist
from petstore_api.models.tag import Tag
@@ -27,7 +27,7 @@ class ArrayOfArrayOfModel(BaseModel):
ArrayOfArrayOfModel
"""
another_property: Optional[conlist(conlist(Tag))] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["another_property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_number_only.py
index 9ec3b1c8fa6c..a73984ae76d8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_array_of_number_only.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictFloat, conlist
class ArrayOfArrayOfNumberOnly(BaseModel):
@@ -26,7 +26,7 @@ class ArrayOfArrayOfNumberOnly(BaseModel):
ArrayOfArrayOfNumberOnly
"""
array_array_number: Optional[conlist(conlist(StrictFloat))] = Field(default=None, alias="ArrayArrayNumber")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["ArrayArrayNumber"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_map_model.py
index 8d502b5ab63d..c599f5484812 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_map_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, conlist
from petstore_api.models.tag import Tag
@@ -26,8 +26,8 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
"""
- array_of_map_property: Optional[conlist(Dict[str, Tag])] = None
- additional_properties: Dict[str, Any] = {}
+ array_of_map_property: Optional[conlist(dict[str, Tag])] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["array_of_map_property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_number_only.py
index 2b995cdf3c1a..a4135161e8a7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_of_number_only.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictFloat, conlist
class ArrayOfNumberOnly(BaseModel):
@@ -26,7 +26,7 @@ class ArrayOfNumberOnly(BaseModel):
ArrayOfNumberOnly
"""
array_number: Optional[conlist(StrictFloat)] = Field(default=None, alias="ArrayNumber")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["ArrayNumber"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_test.py
index 399c66702c53..a3d693d2624e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/array_test.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictFloat, StrictInt, StrictStr, conlist
from petstore_api.models.read_only_first import ReadOnlyFirst
@@ -30,7 +30,7 @@ class ArrayTest(BaseModel):
array_of_nullable_float: Optional[conlist(StrictFloat)] = None
array_array_of_integer: Optional[conlist(conlist(StrictInt))] = None
array_array_of_model: Optional[conlist(conlist(ReadOnlyFirst))] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/base_discriminator.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/base_discriminator.py
index 663cf259f882..d9b6e7a13383 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/base_discriminator.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/base_discriminator.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional, Union
+from typing import Any, Optional, Union
from pydantic import BaseModel, Field, StrictStr
from typing import TYPE_CHECKING
@@ -32,7 +32,7 @@ class BaseDiscriminator(BaseModel):
BaseDiscriminator
"""
type_name: Optional[StrictStr] = Field(default=None, alias="_typeName")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_typeName"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/basque_pig.py
index 00c6cacbb8e8..368e93dd2c03 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/basque_pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/basque_pig.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr
class BasquePig(BaseModel):
@@ -27,7 +27,7 @@ class BasquePig(BaseModel):
"""
class_name: StrictStr = Field(default=..., alias="className")
color: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["className", "color"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/bathing.py
index a167526a6209..ff45a88f9459 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/bathing.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/bathing.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr, validator
class Bathing(BaseModel):
@@ -28,7 +28,7 @@ class Bathing(BaseModel):
task_name: StrictStr = Field(...)
function_name: StrictStr = Field(...)
content: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["task_name", "function_name", "content"]
@validator('task_name')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/capitalization.py
index 862b38b39403..1455c30349da 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/capitalization.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/capitalization.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class Capitalization(BaseModel):
@@ -31,7 +31,7 @@ class Capitalization(BaseModel):
capital_snake: Optional[StrictStr] = Field(default=None, alias="Capital_Snake")
sca_eth_flow_points: Optional[StrictStr] = Field(default=None, alias="SCA_ETH_Flow_Points")
att_name: Optional[StrictStr] = Field(default=None, alias="ATT_NAME", description="Name of the pet ")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/cat.py
index b5dd4c4b08da..e7c2d4d923df 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/cat.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/cat.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import StrictBool
from petstore_api.models.animal import Animal
@@ -27,7 +27,7 @@ class Cat(Animal):
Cat
"""
declawed: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["className", "color", "declawed"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/category.py
index 068827c38788..376008504438 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/category.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/category.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr
class Category(BaseModel):
@@ -27,7 +27,7 @@ class Category(BaseModel):
"""
id: Optional[StrictInt] = None
name: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_all_of_ref.py
index 1ab1def59ac5..e51094503e13 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_all_of_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class CircularAllOfRef(BaseModel):
@@ -27,7 +27,7 @@ class CircularAllOfRef(BaseModel):
"""
name: Optional[StrictStr] = Field(default=None, alias="_name")
second_circular_all_of_ref: Optional[conlist(SecondCircularAllOfRef)] = Field(default=None, alias="secondCircularAllOfRef")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_name", "secondCircularAllOfRef"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_reference_model.py
index 68a202082b28..b057d0f2bf9d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_reference_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/circular_reference_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictInt
class CircularReferenceModel(BaseModel):
@@ -27,7 +27,7 @@ class CircularReferenceModel(BaseModel):
"""
size: Optional[StrictInt] = None
nested: Optional[FirstRef] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["size", "nested"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/class_model.py
index 74cd65c5bc06..65889decfb51 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/class_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/class_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class ClassModel(BaseModel):
@@ -26,7 +26,7 @@ class ClassModel(BaseModel):
Model for testing model with \"_class\" property # noqa: E501
"""
var_class: Optional[StrictStr] = Field(default=None, alias="_class")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_class"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/client.py
index b527c6e6aeed..bf0a40fd4ebb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/client.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/client.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class Client(BaseModel):
@@ -26,7 +26,7 @@ class Client(BaseModel):
Client
"""
client: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["client"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/color.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/color.py
index 8500a75d8325..3fd74c2c8e08 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/color.py
@@ -18,28 +18,28 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, conlist, constr, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
+ # data type: list[int]
oneof_schema_1_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=3, min_items=3)] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
+ # data type: list[int]
oneof_schema_2_validator: Optional[conlist(conint(strict=True, le=255, ge=0), max_items=4, min_items=4)] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[constr(strict=True, max_length=7, min_length=7)] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Union[List[int], str]
+ actual_instance: Union[list[int], str]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(COLOR_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(COLOR_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
@@ -62,13 +62,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -82,10 +82,10 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@@ -103,7 +103,7 @@ def from_json(cls, json_str: str) -> Color:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -112,7 +112,7 @@ def from_json(cls, json_str: str) -> Color:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -133,10 +133,10 @@ def from_json(cls, json_str: str) -> Color:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature.py
index ba3d98a911c3..80a7d3b5ee1e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Union
+from typing import Any, Union
from pydantic import BaseModel, Field, StrictStr
from petstore_api.models.creature_info import CreatureInfo
@@ -33,7 +33,7 @@ class Creature(BaseModel):
"""
info: CreatureInfo = Field(...)
type: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["info", "type"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature_info.py
index bdc45b05b777..847a797fe729 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature_info.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/creature_info.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr
class CreatureInfo(BaseModel):
@@ -26,7 +26,7 @@ class CreatureInfo(BaseModel):
CreatureInfo
"""
name: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/danish_pig.py
index 640a2efec2ad..07af737e5bfc 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/danish_pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/danish_pig.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictInt, StrictStr
class DanishPig(BaseModel):
@@ -27,7 +27,7 @@ class DanishPig(BaseModel):
"""
class_name: StrictStr = Field(default=..., alias="className")
size: StrictInt = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["className", "size"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/deprecated_object.py
index 4e9dc9ddf75e..ad2a41370a35 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/deprecated_object.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/deprecated_object.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class DeprecatedObject(BaseModel):
@@ -26,7 +26,7 @@ class DeprecatedObject(BaseModel):
DeprecatedObject
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_sub.py
index 271339926344..94ab2ed812f0 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_sub.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_sub.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from petstore_api.models.discriminator_all_of_super import DiscriminatorAllOfSuper
@@ -26,7 +26,7 @@ class DiscriminatorAllOfSub(DiscriminatorAllOfSuper):
"""
DiscriminatorAllOfSub
"""
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["elementType"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_super.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_super.py
index 07b83b0f65c5..b1d3b20c2ad6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_super.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/discriminator_all_of_super.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Union
+from typing import Any, Union
from pydantic import BaseModel, Field, StrictStr
from typing import TYPE_CHECKING
@@ -31,7 +31,7 @@ class DiscriminatorAllOfSuper(BaseModel):
DiscriminatorAllOfSuper
"""
element_type: StrictStr = Field(default=..., alias="elementType")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["elementType"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dog.py
index 6317e1fe32a0..900f957d7c49 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dog.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dog.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import StrictStr
from petstore_api.models.animal import Animal
@@ -27,7 +27,7 @@ class Dog(Animal):
Dog
"""
breed: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["className", "color", "breed"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dummy_model.py
index 951906fd28e5..29e3032d98aa 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dummy_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/dummy_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class DummyModel(BaseModel):
@@ -27,7 +27,7 @@ class DummyModel(BaseModel):
"""
category: Optional[StrictStr] = None
self_ref: Optional[SelfReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["category", "self_ref"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_arrays.py
index 4234f3968fe0..04c4be971067 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_arrays.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr, conlist, validator
class EnumArrays(BaseModel):
@@ -27,7 +27,7 @@ class EnumArrays(BaseModel):
"""
just_symbol: Optional[StrictStr] = None
array_enum: Optional[conlist(StrictStr)] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["just_symbol", "array_enum"]
@validator('just_symbol')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_ref_with_default_value.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_ref_with_default_value.py
index f40852f5bbd3..b4e7dd7099b7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_ref_with_default_value.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_ref_with_default_value.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel
from petstore_api.models.data_output_format import DataOutputFormat
@@ -27,7 +27,7 @@ class EnumRefWithDefaultValue(BaseModel):
EnumRefWithDefaultValue
"""
report_format: Optional[DataOutputFormat] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["report_format"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_test.py
index bd18624a5d08..5e174832e74d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/enum_test.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictFloat, StrictInt, StrictStr, validator
from petstore_api.models.enum_number_vendor_ext import EnumNumberVendorExt
from petstore_api.models.enum_string_vendor_ext import EnumStringVendorExt
@@ -44,7 +44,7 @@ class EnumTest(BaseModel):
outer_enum_integer_default_value: Optional[OuterEnumIntegerDefaultValue] = Field(default=None, alias="outerEnumIntegerDefaultValue")
enum_number_vendor_ext: Optional[EnumNumberVendorExt] = Field(default=None, alias="enumNumberVendorExt")
enum_string_vendor_ext: Optional[EnumStringVendorExt] = Field(default=None, alias="enumStringVendorExt")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
@validator('enum_string')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/feeding.py
index 3f4ba3f81eb6..86781f127aef 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/feeding.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/feeding.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr, validator
class Feeding(BaseModel):
@@ -28,7 +28,7 @@ class Feeding(BaseModel):
task_name: StrictStr = Field(...)
function_name: StrictStr = Field(...)
content: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["task_name", "function_name", "content"]
@validator('task_name')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/field.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/field.py
index c73388ec0650..c08d2fb6d2c1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/field.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/field.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class Field(BaseModel):
@@ -26,7 +26,7 @@ class Field(BaseModel):
Field
"""
field: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["field"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file.py
index 536288cb54a9..cb4ea7e8cf7d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class File(BaseModel):
@@ -26,7 +26,7 @@ class File(BaseModel):
Must be named `File` for test. # noqa: E501
"""
source_uri: Optional[StrictStr] = Field(default=None, alias="sourceURI", description="Test capitalization")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["sourceURI"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file_schema_test_class.py
index efbb7d95f03d..ca55fca9331f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/file_schema_test_class.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, conlist
from petstore_api.models.file import File
@@ -28,7 +28,7 @@ class FileSchemaTestClass(BaseModel):
"""
file: Optional[File] = None
files: Optional[conlist(File)] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["file", "files"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/first_ref.py
index 5a44cd22c7e6..ce16b05e8465 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/first_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/first_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class FirstRef(BaseModel):
@@ -27,7 +27,7 @@ class FirstRef(BaseModel):
"""
category: Optional[StrictStr] = None
self_ref: Optional[SecondRef] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["category", "self_ref"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo.py
index 77f2ef9a359a..ccd61cfc8c1d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class Foo(BaseModel):
@@ -26,7 +26,7 @@ class Foo(BaseModel):
Foo
"""
bar: Optional[StrictStr] = 'bar'
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["bar"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo_get_default_response.py
index 3eb736a411e3..813827694f50 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo_get_default_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/foo_get_default_response.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel
from petstore_api.models.foo import Foo
@@ -27,7 +27,7 @@ class FooGetDefaultResponse(BaseModel):
FooGetDefaultResponse
"""
string: Optional[Foo] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["string"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/format_test.py
index eb58bc67ef20..74adc5921b46 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/format_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/format_test.py
@@ -18,7 +18,7 @@
import json
from datetime import date, datetime
-from typing import Any, Dict, Optional, Union
+from typing import Any, Optional, Union
from pydantic import BaseModel, Field, StrictBytes, StrictInt, StrictStr, condecimal, confloat, conint, constr, validator
class FormatTest(BaseModel):
@@ -42,7 +42,7 @@ class FormatTest(BaseModel):
password: constr(strict=True, max_length=64, min_length=10) = Field(...)
pattern_with_digits: Optional[constr(strict=True)] = Field(default=None, description="A string that is a 10 digit number. Can have leading zeros.")
pattern_with_digits_and_delimiter: Optional[constr(strict=True)] = Field(default=None, description="A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
@validator('string')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/has_only_read_only.py
index be7b0eb636b3..0aa2dd3e029a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/has_only_read_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/has_only_read_only.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class HasOnlyReadOnly(BaseModel):
@@ -27,7 +27,7 @@ class HasOnlyReadOnly(BaseModel):
"""
bar: Optional[StrictStr] = None
foo: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["bar", "foo"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/health_check_result.py
index aeb92fcd8245..3c1d53d0ab70 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/health_check_result.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/health_check_result.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class HealthCheckResult(BaseModel):
@@ -26,7 +26,7 @@ class HealthCheckResult(BaseModel):
Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model. # noqa: E501
"""
nullable_message: Optional[StrictStr] = Field(default=None, alias="NullableMessage")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["NullableMessage"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/hunting_dog.py
index 6637553d36d7..1220011f552c 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/hunting_dog.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/hunting_dog.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictBool
from petstore_api.models.creature import Creature
from petstore_api.models.creature_info import CreatureInfo
@@ -28,7 +28,7 @@ class HuntingDog(Creature):
HuntingDog
"""
is_trained: Optional[StrictBool] = Field(default=None, alias="isTrained")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["info", "type", "isTrained"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/info.py
index 46ea104c0a70..1ccccc381f6e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/info.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/info.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
@@ -27,7 +27,7 @@ class Info(BaseDiscriminator):
Info
"""
val: Optional[BaseDiscriminator] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_typeName", "val"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/inner_dict_with_property.py
index 8b51675279ef..9db6e84cc0e3 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/inner_dict_with_property.py
@@ -18,15 +18,15 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field
class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
"""
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
- additional_properties: Dict[str, Any] = {}
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
+ additional_properties: dict[str, Any] = {}
__properties = ["aProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/input_all_of.py
index 432db3528137..a071ee782ff2 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/input_all_of.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel
from petstore_api.models.tag import Tag
@@ -26,8 +26,8 @@ class InputAllOf(BaseModel):
"""
InputAllOf
"""
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["some_data"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/int_or_string.py
index 5d5de47e305a..92673590bfd4 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/int_or_string.py
@@ -18,9 +18,9 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, conint, validator
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -37,7 +37,7 @@ class IntOrString(BaseModel):
actual_instance: Union[int, str]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(INTORSTRING_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(INTORSTRING_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/list_class.py
index 28a3ae597ebf..b2de115fd903 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/list_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/list_class.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class ListClass(BaseModel):
@@ -26,7 +26,7 @@ class ListClass(BaseModel):
ListClass
"""
var_123_list: Optional[StrictStr] = Field(default=None, alias="123-list")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["123-list"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_of_array_of_model.py
index 75b4d19cbde4..6555fe8c36b0 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_of_array_of_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.tag import Tag
@@ -26,8 +26,8 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
"""
- shop_id_to_org_online_lip_map: Optional[Dict[str, conlist(Tag)]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
- additional_properties: Dict[str, Any] = {}
+ shop_id_to_org_online_lip_map: Optional[dict[str, conlist(Tag)]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ additional_properties: dict[str, Any] = {}
__properties = ["shopIdToOrgOnlineLipMap"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_test.py
index a6c761dfa2a8..4eb873e4b630 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/map_test.py
@@ -18,18 +18,18 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictBool, StrictStr, validator
class MapTest(BaseModel):
"""
MapTest
"""
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
- additional_properties: Dict[str, Any] = {}
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@validator('map_of_enum_string')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/mixed_properties_and_additional_properties_class.py
index 8027a4a36dee..4bc7bf50924e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -18,7 +18,7 @@
import json
from datetime import datetime
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
from petstore_api.models.animal import Animal
@@ -28,8 +28,8 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
"""
uuid: Optional[StrictStr] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
- additional_properties: Dict[str, Any] = {}
+ map: Optional[dict[str, Animal]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["uuid", "dateTime", "map"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model200_response.py
index 9748057408fa..47104e70187a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model200_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model200_response.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr
class Model200Response(BaseModel):
@@ -27,7 +27,7 @@ class Model200Response(BaseModel):
"""
name: Optional[StrictInt] = None
var_class: Optional[StrictStr] = Field(default=None, alias="class")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name", "class"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model_return.py
index 8d6497a11257..f1b178798400 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model_return.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/model_return.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt
class ModelReturn(BaseModel):
@@ -26,7 +26,7 @@ class ModelReturn(BaseModel):
Model for testing reserved words # noqa: E501
"""
var_return: Optional[StrictInt] = Field(default=None, alias="return")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["return"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/multi_arrays.py
index f7bfff779303..4974be9a8eb5 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/multi_arrays.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
@@ -29,7 +29,7 @@ class MultiArrays(BaseModel):
"""
tags: Optional[conlist(Tag)] = None
files: Optional[conlist(File)] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["tags", "files"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/name.py
index 183604e4a14d..6a5457ccfbdd 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/name.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/name.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr
class Name(BaseModel):
@@ -29,7 +29,7 @@ class Name(BaseModel):
snake_case: Optional[StrictInt] = None
var_property: Optional[StrictStr] = Field(default=None, alias="property")
var_123_number: Optional[StrictInt] = Field(default=None, alias="123Number")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name", "snake_case", "property", "123Number"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_class.py
index 578579888444..bccd06b45b00 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_class.py
@@ -18,7 +18,7 @@
import json
from datetime import date, datetime
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictBool, StrictFloat, StrictInt, StrictStr, conlist
class NullableClass(BaseModel):
@@ -32,13 +32,13 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[conlist(Dict[str, Any])] = None
- array_and_items_nullable_prop: Optional[conlist(Dict[str, Any])] = None
- array_items_nullable: Optional[conlist(Dict[str, Any])] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_items_nullable: Optional[Dict[str, Dict[str, Any]]] = None
- additional_properties: Dict[str, Any] = {}
+ array_nullable_prop: Optional[conlist(dict[str, Any])] = None
+ array_and_items_nullable_prop: Optional[conlist(dict[str, Any])] = None
+ array_items_nullable: Optional[conlist(dict[str, Any])] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_items_nullable: Optional[dict[str, dict[str, Any]]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_property.py
index 059cbdc577cb..8813038ef5d5 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_property.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/nullable_property.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, constr, validator
class NullableProperty(BaseModel):
@@ -27,7 +27,7 @@ class NullableProperty(BaseModel):
"""
id: StrictInt = Field(...)
name: Optional[constr(strict=True)] = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "name"]
@validator('name')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/number_only.py
index 398bb70c2cb5..379c584eb07a 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/number_only.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/number_only.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictFloat
class NumberOnly(BaseModel):
@@ -26,7 +26,7 @@ class NumberOnly(BaseModel):
NumberOnly
"""
just_number: Optional[StrictFloat] = Field(default=None, alias="JustNumber")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["JustNumber"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_to_test_additional_properties.py
index b8df7a0128e2..cc3db1a9c2d1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_to_test_additional_properties.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_to_test_additional_properties.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictBool
class ObjectToTestAdditionalProperties(BaseModel):
@@ -26,7 +26,7 @@ class ObjectToTestAdditionalProperties(BaseModel):
Minimal object # noqa: E501
"""
var_property: Optional[StrictBool] = Field(default=False, alias="property", description="Property")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["property"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_with_deprecated_fields.py
index 58e174846e9e..269365d202a1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/object_with_deprecated_fields.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictFloat, StrictStr, conlist
from petstore_api.models.deprecated_object import DeprecatedObject
@@ -30,7 +30,7 @@ class ObjectWithDeprecatedFields(BaseModel):
id: Optional[StrictFloat] = None
deprecated_ref: Optional[DeprecatedObject] = Field(default=None, alias="deprecatedRef")
bars: Optional[conlist(StrictStr)] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["uuid", "id", "deprecatedRef", "bars"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/one_of_enum_string.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/one_of_enum_string.py
index d7ae93ccb6a8..e4c850d67efe 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/one_of_enum_string.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/one_of_enum_string.py
@@ -18,11 +18,11 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.enum_string1 import EnumString1
from petstore_api.models.enum_string2 import EnumString2
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
ONEOFENUMSTRING_ONE_OF_SCHEMAS = ["EnumString1", "EnumString2"]
@@ -39,7 +39,7 @@ class OneOfEnumString(BaseModel):
actual_instance: Union[EnumString1, EnumString2]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(ONEOFENUMSTRING_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(ONEOFENUMSTRING_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/order.py
index 635f1351ae4d..8d73fccf9bb6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/order.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/order.py
@@ -18,7 +18,7 @@
import json
from datetime import datetime
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictBool, StrictInt, StrictStr, validator
class Order(BaseModel):
@@ -31,7 +31,7 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@validator('status')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_composite.py
index b453339e1c87..13a930fa2ca4 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_composite.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_composite.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictBool, StrictFloat, StrictStr
class OuterComposite(BaseModel):
@@ -28,7 +28,7 @@ class OuterComposite(BaseModel):
my_number: Optional[StrictFloat] = None
my_string: Optional[StrictStr] = None
my_boolean: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["my_number", "my_string", "my_boolean"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_object_with_enum_property.py
index a5723f0a9321..72fbc8f82eee 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_object_with_enum_property.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/outer_object_with_enum_property.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_integer import OuterEnumInteger
@@ -29,7 +29,7 @@ class OuterObjectWithEnumProperty(BaseModel):
"""
str_value: Optional[OuterEnum] = None
value: OuterEnumInteger = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["str_value", "value"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent.py
index 1a3062606c6b..f39094d7cbfb 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
@@ -26,8 +26,8 @@ class Parent(BaseModel):
"""
Parent
"""
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
__properties = ["optionalDict"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent_with_optional_dict.py
index 4e82d77b067a..aef153952c0e 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/parent_with_optional_dict.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
@@ -26,8 +26,8 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
"""
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
__properties = ["optionalDict"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pet.py
index 2b29315173bd..8c2f46ca6477 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pet.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr, conlist, validator
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
@@ -33,7 +33,7 @@ class Pet(BaseModel):
photo_urls: conlist(StrictStr, min_items=0, unique_items=True) = Field(default=..., alias="photoUrls")
tags: Optional[conlist(Tag)] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "category", "name", "photoUrls", "tags", "status"]
@validator('status')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pig.py
index 62ae5a2a0ef7..059abffe1c31 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pig.py
@@ -18,11 +18,11 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -39,7 +39,7 @@ class Pig(BaseModel):
actual_instance: Union[BasquePig, DanishPig]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(PIG_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(PIG_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pony_sizes.py
index 2d04b866cb17..f7530b2ccf85 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pony_sizes.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/pony_sizes.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel
from petstore_api.models.type import Type
@@ -27,7 +27,7 @@ class PonySizes(BaseModel):
PonySizes
"""
type: Optional[Type] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["type"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/poop_cleaning.py
index f6c7e3d2f04c..a48d59a6ed1f 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/poop_cleaning.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/poop_cleaning.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr, validator
class PoopCleaning(BaseModel):
@@ -28,7 +28,7 @@ class PoopCleaning(BaseModel):
task_name: StrictStr = Field(...)
function_name: StrictStr = Field(...)
content: StrictStr = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["task_name", "function_name", "content"]
@validator('task_name')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/primitive_string.py
index b67daec1d987..a479b72196e3 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/primitive_string.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/primitive_string.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import Field, StrictStr
from petstore_api.models.base_discriminator import BaseDiscriminator
@@ -27,7 +27,7 @@ class PrimitiveString(BaseDiscriminator):
PrimitiveString
"""
value: Optional[StrictStr] = Field(default=None, alias="_value")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_typeName", "_value"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_map.py
index 9dd582eefaa2..c24e28fd3822 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_map.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel
from petstore_api.models.tag import Tag
@@ -26,8 +26,8 @@ class PropertyMap(BaseModel):
"""
PropertyMap
"""
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
__properties = ["some_data"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_name_collision.py
index 355b3b2cd119..04218003f147 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_name_collision.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/property_name_collision.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class PropertyNameCollision(BaseModel):
@@ -28,7 +28,7 @@ class PropertyNameCollision(BaseModel):
underscore_type: Optional[StrictStr] = Field(default=None, alias="_type")
type: Optional[StrictStr] = None
type_with_underscore: Optional[StrictStr] = Field(default=None, alias="type_")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_type", "type", "type_"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/read_only_first.py
index cfaf97c7091e..a1fd6a3fd3f9 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/read_only_first.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/read_only_first.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class ReadOnlyFirst(BaseModel):
@@ -27,7 +27,7 @@ class ReadOnlyFirst(BaseModel):
"""
bar: Optional[StrictStr] = None
baz: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["bar", "baz"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_circular_all_of_ref.py
index 328df27a5848..7416c9b9c7b8 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_circular_all_of_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class SecondCircularAllOfRef(BaseModel):
@@ -27,7 +27,7 @@ class SecondCircularAllOfRef(BaseModel):
"""
name: Optional[StrictStr] = Field(default=None, alias="_name")
circular_all_of_ref: Optional[conlist(CircularAllOfRef)] = Field(default=None, alias="circularAllOfRef")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["_name", "circularAllOfRef"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_ref.py
index 2f0c99ae1b90..20cf447371b6 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_ref.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/second_ref.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class SecondRef(BaseModel):
@@ -27,7 +27,7 @@ class SecondRef(BaseModel):
"""
category: Optional[StrictStr] = None
circular_ref: Optional[CircularReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["category", "circular_ref"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/self_reference_model.py
index 55512492d8e9..2883a40b1e12 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/self_reference_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/self_reference_model.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictInt
class SelfReferenceModel(BaseModel):
@@ -27,7 +27,7 @@ class SelfReferenceModel(BaseModel):
"""
size: Optional[StrictInt] = None
nested: Optional[DummyModel] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["size", "nested"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_model_name.py
index c9e8872aac40..e9f9477e58e7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_model_name.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_model_name.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt
class SpecialModelName(BaseModel):
@@ -26,7 +26,7 @@ class SpecialModelName(BaseModel):
SpecialModelName
"""
special_property_name: Optional[StrictInt] = Field(default=None, alias="$special[property.name]")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["$special[property.name]"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_name.py
index 71b40ec332ab..da50ab1af901 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_name.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/special_name.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr, validator
from petstore_api.models.category import Category
@@ -29,7 +29,7 @@ class SpecialName(BaseModel):
var_property: Optional[StrictInt] = Field(default=None, alias="property")
var_async: Optional[Category] = Field(default=None, alias="async")
var_schema: Optional[StrictStr] = Field(default=None, alias="schema", description="pet status in the store")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["property", "async", "schema"]
@validator('var_schema')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tag.py
index 299159859552..d38894a907e2 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tag.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tag.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictInt, StrictStr
class Tag(BaseModel):
@@ -27,7 +27,7 @@ class Tag(BaseModel):
"""
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task.py
index 3bcc9d0c3f22..1779320a39f3 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict
+from typing import Any
from pydantic import BaseModel, Field, StrictStr
from petstore_api.models.task_activity import TaskActivity
@@ -28,7 +28,7 @@ class Task(BaseModel):
"""
id: StrictStr = Field(...)
activity: TaskActivity = Field(...)
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "activity"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task_activity.py
index 70553f1ef202..f671aff56754 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/task_activity.py
@@ -18,12 +18,12 @@
import pprint
import re # noqa: F401
-from typing import Any, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, ValidationError, validator
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
-from typing import Union, Any, List, TYPE_CHECKING
+from typing import Union, Any, TYPE_CHECKING
from pydantic import StrictStr, Field
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -42,7 +42,7 @@ class TaskActivity(BaseModel):
actual_instance: Union[Bathing, Feeding, PoopCleaning]
else:
actual_instance: Any
- one_of_schemas: List[str] = Field(TASKACTIVITY_ONE_OF_SCHEMAS, const=True)
+ one_of_schemas: list[str] = Field(TASKACTIVITY_ONE_OF_SCHEMAS, const=True)
class Config:
validate_assignment = True
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model400_response.py
index 40855d008cce..0d7394aa4094 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model400_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model400_response.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class TestErrorResponsesWithModel400Response(BaseModel):
@@ -26,7 +26,7 @@ class TestErrorResponsesWithModel400Response(BaseModel):
TestErrorResponsesWithModel400Response
"""
reason400: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["reason400"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model404_response.py
index 77c77d903f53..070c601cb7cc 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model404_response.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_error_responses_with_model404_response.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class TestErrorResponsesWithModel404Response(BaseModel):
@@ -26,7 +26,7 @@ class TestErrorResponsesWithModel404Response(BaseModel):
TestErrorResponsesWithModel404Response
"""
reason404: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["reason404"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 09dc01dbd972..bd0d3acebe48 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr
class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
@@ -26,7 +26,7 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
"""
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["someProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_model_with_enum_default.py
index 3775fd5e29c2..e0dbff76ec74 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_model_with_enum_default.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_model_with_enum_default.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, validator
from petstore_api.models.test_enum import TestEnum
from petstore_api.models.test_enum_with_default import TestEnumWithDefault
@@ -32,7 +32,7 @@ class TestModelWithEnumDefault(BaseModel):
test_enum_with_default: Optional[TestEnumWithDefault] = None
test_string_with_default: Optional[StrictStr] = 'ahoy matey'
test_inline_defined_enum_with_default: Optional[StrictStr] = 'B'
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
@validator('test_inline_defined_enum_with_default')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_object_for_multipart_requests_request_marker.py
index 92b02afed6c7..b6f869e6d0dc 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_object_for_multipart_requests_request_marker.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/test_object_for_multipart_requests_request_marker.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class TestObjectForMultipartRequestsRequestMarker(BaseModel):
@@ -26,7 +26,7 @@ class TestObjectForMultipartRequestsRequestMarker(BaseModel):
TestObjectForMultipartRequestsRequestMarker
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tiger.py
index 71453dcec366..49260775bf75 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tiger.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/tiger.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class Tiger(BaseModel):
@@ -26,7 +26,7 @@ class Tiger(BaseModel):
Tiger
"""
skill: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["skill"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index 1c42bf0b47c3..abd07c831cb1 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, conlist
from petstore_api.models.creature_info import CreatureInfo
@@ -26,8 +26,8 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
"""
- dict_property: Optional[Dict[str, conlist(CreatureInfo)]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
+ dict_property: Optional[dict[str, conlist(CreatureInfo)]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
__properties = ["dictProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index d9db4ee370c6..a8dbee6f63ad 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,15 +18,15 @@
import json
-from typing import Any, Dict, List, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictStr, conlist
class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
"""
- dict_property: Optional[Dict[str, conlist(StrictStr)]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
+ dict_property: Optional[dict[str, conlist(StrictStr)]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
__properties = ["dictProperty"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/upload_file_with_additional_properties_request_object.py
index a8820b0262b4..c9d004fb1b9d 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/upload_file_with_additional_properties_request_object.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/upload_file_with_additional_properties_request_object.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictStr
class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
@@ -26,7 +26,7 @@ class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
Additional object # noqa: E501
"""
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["name"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/user.py
index 89b813092a71..429a31223ff9 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/user.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/user.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, Field, StrictInt, StrictStr
class User(BaseModel):
@@ -33,7 +33,7 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, alias="userStatus", description="User Status")
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/uuid_with_pattern.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/uuid_with_pattern.py
index b146f3c8f4c4..dd33a933caf7 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/uuid_with_pattern.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/uuid_with_pattern.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, constr, validator
class UuidWithPattern(BaseModel):
@@ -26,7 +26,7 @@ class UuidWithPattern(BaseModel):
UuidWithPattern
"""
id: Optional[constr(strict=True)] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["id"]
@validator('id')
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/with_nested_one_of.py
index 8ec40c8eda1e..45f1df7ce166 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/with_nested_one_of.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/petstore_api/models/with_nested_one_of.py
@@ -18,7 +18,7 @@
import json
-from typing import Any, Dict, Optional
+from typing import Any, Optional
from pydantic import BaseModel, StrictInt
from petstore_api.models.one_of_enum_string import OneOfEnumString
from petstore_api.models.pig import Pig
@@ -30,7 +30,7 @@ class WithNestedOneOf(BaseModel):
size: Optional[StrictInt] = None
nested_pig: Optional[Pig] = None
nested_oneof_enum_string: Optional[OneOfEnumString] = None
- additional_properties: Dict[str, Any] = {}
+ additional_properties: dict[str, Any] = {}
__properties = ["size", "nested_pig", "nested_oneof_enum_string"]
class Config:
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_deserialization.py b/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_deserialization.py
index c5fb68663821..1ee7b785a901 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_deserialization.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_deserialization.py
@@ -29,7 +29,7 @@ def setUp(self):
self.deserialize = self.api_client.deserialize
def test_enum_test(self):
- """ deserialize Dict[str, EnumTest] """
+ """ deserialize dict[str, EnumTest] """
data = {
'enum_test': {
"enum_string": "UPPER",
@@ -41,7 +41,7 @@ def test_enum_test(self):
}
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, 'Dict[str, EnumTest]')
+ deserialized = self.deserialize(response, 'dict[str, EnumTest]')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['enum_test'], petstore_api.EnumTest))
self.assertEqual(deserialized['enum_test'],
@@ -52,7 +52,7 @@ def test_enum_test(self):
outer_enum=petstore_api.OuterEnum.PLACED))
def test_deserialize_dict_str_pet(self):
- """ deserialize Dict[str, Pet] """
+ """ deserialize dict[str, Pet] """
data = {
'pet': {
"id": 0,
@@ -75,13 +75,13 @@ def test_deserialize_dict_str_pet(self):
}
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, 'Dict[str, Pet]')
+ deserialized = self.deserialize(response, 'dict[str, Pet]')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['pet'], petstore_api.Pet))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_dog(self):
- """ deserialize Dict[str, Animal], use discriminator"""
+ """ deserialize dict[str, Animal], use discriminator"""
data = {
'dog': {
"id": 0,
@@ -92,19 +92,19 @@ def test_deserialize_dict_str_dog(self):
}
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, 'Dict[str, Animal]')
+ deserialized = self.deserialize(response, 'dict[str, Animal]')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['dog'], petstore_api.Dog))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_int(self):
- """ deserialize Dict[str, int] """
+ """ deserialize dict[str, int] """
data = {
'integer': 1
}
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, 'Dict[str, int]')
+ deserialized = self.deserialize(response, 'dict[str, int]')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['integer'], int))
@@ -204,7 +204,7 @@ def test_deserialize_list_of_pet(self):
}]
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, "List[Pet]")
+ deserialized = self.deserialize(response, "list[Pet]")
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], petstore_api.Pet))
self.assertEqual(deserialized[0].id, 0)
@@ -213,7 +213,7 @@ def test_deserialize_list_of_pet(self):
self.assertEqual(deserialized[1].name, "doggie1")
def test_deserialize_nested_dict(self):
- """ deserialize Dict[str, Dict[str, int]] """
+ """ deserialize dict[str, dict[str, int]] """
data = {
"foo": {
"bar": 1
@@ -221,7 +221,7 @@ def test_deserialize_nested_dict(self):
}
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, "Dict[str, Dict[str, int]]")
+ deserialized = self.deserialize(response, "dict[str, dict[str, int]]")
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized["foo"], dict))
self.assertTrue(isinstance(deserialized["foo"]["bar"], int))
@@ -231,7 +231,7 @@ def test_deserialize_nested_list(self):
data = [["foo"]]
response = MockResponse(data=json.dumps(data))
- deserialized = self.deserialize(response, "List[List[str]]")
+ deserialized = self.deserialize(response, "list[list[str]]")
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], list))
self.assertTrue(isinstance(deserialized[0][0], str))
diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_model.py b/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_model.py
index aee61bf79d9b..5d7284c346ba 100644
--- a/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_model.py
+++ b/samples/openapi3/client/petstore/python-pydantic-v1/tests/test_model.py
@@ -345,7 +345,7 @@ def test_list(self):
self.assertTrue(False) # this line shouldn't execute
except ValueError as e:
#error_message = (
- # "1 validation error for List\n"
+ # "1 validation error for list\n"
# "123-list\n"
# " str type expected (type=type_error.str)\n")
self.assertTrue("str type expected" in str(e))
diff --git a/samples/openapi3/client/petstore/python/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python/docs/AdditionalPropertiesClass.md
index 5128004d8f9a..faa22e6e6b1b 100644
--- a/samples/openapi3/client/petstore/python/docs/AdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python/docs/AdditionalPropertiesClass.md
@@ -5,9 +5,9 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_property** | **Dict[str, str]** | | [optional]
-**map_of_map_property** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_map_non_primitive_property** | **Dict[str, Dict[str, Pet]]** | | [optional]
+**map_property** | **dict[str, str]** | | [optional]
+**map_of_map_property** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_map_non_primitive_property** | **dict[str, dict[str, Pet]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfModel.md b/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfModel.md
index f866863d53f9..13c6bc20804d 100644
--- a/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**another_property** | **List[List[Tag]]** | | [optional]
+**another_property** | **list[list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfNumberOnly.md
index 32bd2dfbf1e2..8fa0d5954ad1 100644
--- a/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python/docs/ArrayOfArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_array_number** | **List[List[float]]** | | [optional]
+**array_array_number** | **list[list[float]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ArrayOfMapModel.md b/samples/openapi3/client/petstore/python/docs/ArrayOfMapModel.md
index fd39f86fce5e..44ee01bb37b6 100644
--- a/samples/openapi3/client/petstore/python/docs/ArrayOfMapModel.md
+++ b/samples/openapi3/client/petstore/python/docs/ArrayOfMapModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_map_property** | **List[Dict[str, Tag]]** | | [optional]
+**array_of_map_property** | **list[dict[str, Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/python/docs/ArrayOfNumberOnly.md
index b814d7594942..bc690d09040a 100644
--- a/samples/openapi3/client/petstore/python/docs/ArrayOfNumberOnly.md
+++ b/samples/openapi3/client/petstore/python/docs/ArrayOfNumberOnly.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_number** | **List[float]** | | [optional]
+**array_number** | **list[float]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ArrayTest.md b/samples/openapi3/client/petstore/python/docs/ArrayTest.md
index ed871fae662d..014e64472c22 100644
--- a/samples/openapi3/client/petstore/python/docs/ArrayTest.md
+++ b/samples/openapi3/client/petstore/python/docs/ArrayTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**array_of_string** | **List[str]** | | [optional]
-**array_of_nullable_float** | **List[Optional[float]]** | | [optional]
-**array_array_of_integer** | **List[List[int]]** | | [optional]
-**array_array_of_model** | **List[List[ReadOnlyFirst]]** | | [optional]
+**array_of_string** | **list[str]** | | [optional]
+**array_of_nullable_float** | **list[Optional[float]]** | | [optional]
+**array_array_of_integer** | **list[list[int]]** | | [optional]
+**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/CircularAllOfRef.md b/samples/openapi3/client/petstore/python/docs/CircularAllOfRef.md
index 65b171177e58..d39dfe136b9f 100644
--- a/samples/openapi3/client/petstore/python/docs/CircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python/docs/CircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**second_circular_all_of_ref** | [**List[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
+**second_circular_all_of_ref** | [**list[SecondCircularAllOfRef]**](SecondCircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/EnumArrays.md b/samples/openapi3/client/petstore/python/docs/EnumArrays.md
index f44617497bce..687172987bc6 100644
--- a/samples/openapi3/client/petstore/python/docs/EnumArrays.md
+++ b/samples/openapi3/client/petstore/python/docs/EnumArrays.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**just_symbol** | **str** | | [optional]
-**array_enum** | **List[str]** | | [optional]
+**array_enum** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/FakeApi.md b/samples/openapi3/client/petstore/python/docs/FakeApi.md
index 7ef2af8af2c3..6e42c2b8ddaa 100644
--- a/samples/openapi3/client/petstore/python/docs/FakeApi.md
+++ b/samples/openapi3/client/petstore/python/docs/FakeApi.md
@@ -651,7 +651,7 @@ with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
outer_object_with_enum_property = petstore_api.OuterObjectWithEnumProperty() # OuterObjectWithEnumProperty | Input enum (int) as post body
- param = [petstore_api.OuterEnumInteger()] # List[OuterEnumInteger] | (optional)
+ param = [petstore_api.OuterEnumInteger()] # list[OuterEnumInteger] | (optional)
try:
api_response = api_instance.fake_property_enum_integer_serialize(outer_object_with_enum_property, param=param)
@@ -669,7 +669,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**outer_object_with_enum_property** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body |
- **param** | [**List[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
+ **param** | [**list[OuterEnumInteger]**](OuterEnumInteger.md)| | [optional]
### Return type
@@ -1121,7 +1121,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **fake_return_list_of_objects**
-> List[List[Tag]] fake_return_list_of_objects()
+> list[list[Tag]] fake_return_list_of_objects()
test returning list of objects
@@ -1163,7 +1163,7 @@ This endpoint does not need any parameter.
### Return type
-**List[List[Tag]]**
+**list[list[Tag]]**
### Authorization
@@ -1393,7 +1393,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = None # Dict[str, object] | request body
+ request_body = None # dict[str, object] | request body
try:
# test referenced additionalProperties
@@ -1409,7 +1409,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, object]**](object.md)| request body |
+ **request_body** | [**dict[str, object]**](object.md)| request body |
### Return type
@@ -2093,7 +2093,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test inline additionalProperties
@@ -2109,7 +2109,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
@@ -2350,13 +2350,13 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- pipe = ['pipe_example'] # List[str] |
- ioutil = ['ioutil_example'] # List[str] |
- http = ['http_example'] # List[str] |
- url = ['url_example'] # List[str] |
- context = ['context_example'] # List[str] |
+ pipe = ['pipe_example'] # list[str] |
+ ioutil = ['ioutil_example'] # list[str] |
+ http = ['http_example'] # list[str] |
+ url = ['url_example'] # list[str] |
+ context = ['context_example'] # list[str] |
allow_empty = 'allow_empty_example' # str |
- language = {'key': 'language_example'} # Dict[str, str] | (optional)
+ language = {'key': 'language_example'} # dict[str, str] | (optional)
try:
api_instance.test_query_parameter_collection_format(pipe, ioutil, http, url, context, allow_empty, language=language)
@@ -2371,13 +2371,13 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **pipe** | [**List[str]**](str.md)| |
- **ioutil** | [**List[str]**](str.md)| |
- **http** | [**List[str]**](str.md)| |
- **url** | [**List[str]**](str.md)| |
- **context** | [**List[str]**](str.md)| |
+ **pipe** | [**list[str]**](str.md)| |
+ **ioutil** | [**list[str]**](str.md)| |
+ **http** | [**list[str]**](str.md)| |
+ **url** | [**list[str]**](str.md)| |
+ **context** | [**list[str]**](str.md)| |
**allow_empty** | **str**| |
- **language** | [**Dict[str, str]**](str.md)| | [optional]
+ **language** | [**dict[str, str]**](str.md)| | [optional]
### Return type
@@ -2426,7 +2426,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.FakeApi(api_client)
- request_body = {'key': 'request_body_example'} # Dict[str, str] | request body
+ request_body = {'key': 'request_body_example'} # dict[str, str] | request body
try:
# test referenced string map
@@ -2442,7 +2442,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **request_body** | [**Dict[str, str]**](str.md)| request body |
+ **request_body** | [**dict[str, str]**](str.md)| request body |
### Return type
diff --git a/samples/openapi3/client/petstore/python/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/python/docs/FileSchemaTestClass.md
index e1118042a8ec..aae04a5bbba7 100644
--- a/samples/openapi3/client/petstore/python/docs/FileSchemaTestClass.md
+++ b/samples/openapi3/client/petstore/python/docs/FileSchemaTestClass.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**file** | [**File**](File.md) | | [optional]
-**files** | [**List[File]**](File.md) | | [optional]
+**files** | [**list[File]**](File.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/InputAllOf.md b/samples/openapi3/client/petstore/python/docs/InputAllOf.md
index 45298f5308fc..adc4f9cdcb63 100644
--- a/samples/openapi3/client/petstore/python/docs/InputAllOf.md
+++ b/samples/openapi3/client/petstore/python/docs/InputAllOf.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/MapOfArrayOfModel.md b/samples/openapi3/client/petstore/python/docs/MapOfArrayOfModel.md
index 71a4ef66b682..d2a7c41b46f9 100644
--- a/samples/openapi3/client/petstore/python/docs/MapOfArrayOfModel.md
+++ b/samples/openapi3/client/petstore/python/docs/MapOfArrayOfModel.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**shop_id_to_org_online_lip_map** | **Dict[str, List[Tag]]** | | [optional]
+**shop_id_to_org_online_lip_map** | **dict[str, list[Tag]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/MapTest.md b/samples/openapi3/client/petstore/python/docs/MapTest.md
index d04b82e9378c..33032142168b 100644
--- a/samples/openapi3/client/petstore/python/docs/MapTest.md
+++ b/samples/openapi3/client/petstore/python/docs/MapTest.md
@@ -5,10 +5,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**map_map_of_string** | **Dict[str, Dict[str, str]]** | | [optional]
-**map_of_enum_string** | **Dict[str, str]** | | [optional]
-**direct_map** | **Dict[str, bool]** | | [optional]
-**indirect_map** | **Dict[str, bool]** | | [optional]
+**map_map_of_string** | **dict[str, dict[str, str]]** | | [optional]
+**map_of_enum_string** | **dict[str, str]** | | [optional]
+**direct_map** | **dict[str, bool]** | | [optional]
+**indirect_map** | **dict[str, bool]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/python/docs/MixedPropertiesAndAdditionalPropertiesClass.md
index 84134317aefc..7e5fb0b3071d 100644
--- a/samples/openapi3/client/petstore/python/docs/MixedPropertiesAndAdditionalPropertiesClass.md
+++ b/samples/openapi3/client/petstore/python/docs/MixedPropertiesAndAdditionalPropertiesClass.md
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uuid** | **UUID** | | [optional]
**date_time** | **datetime** | | [optional]
-**map** | [**Dict[str, Animal]**](Animal.md) | | [optional]
+**map** | [**dict[str, Animal]**](Animal.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/MultiArrays.md b/samples/openapi3/client/petstore/python/docs/MultiArrays.md
index fea5139e7e73..62398cd42693 100644
--- a/samples/openapi3/client/petstore/python/docs/MultiArrays.md
+++ b/samples/openapi3/client/petstore/python/docs/MultiArrays.md
@@ -5,8 +5,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
-**files** | [**List[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
+**files** | [**list[File]**](File.md) | Another array of objects in addition to tags (mypy check to not to reuse the same iterator) | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/NullableClass.md b/samples/openapi3/client/petstore/python/docs/NullableClass.md
index 0387dcc2c67a..1378ee707136 100644
--- a/samples/openapi3/client/petstore/python/docs/NullableClass.md
+++ b/samples/openapi3/client/petstore/python/docs/NullableClass.md
@@ -12,12 +12,12 @@ Name | Type | Description | Notes
**string_prop** | **str** | | [optional]
**date_prop** | **date** | | [optional]
**datetime_prop** | **datetime** | | [optional]
-**array_nullable_prop** | **List[object]** | | [optional]
-**array_and_items_nullable_prop** | **List[Optional[object]]** | | [optional]
-**array_items_nullable** | **List[Optional[object]]** | | [optional]
-**object_nullable_prop** | **Dict[str, object]** | | [optional]
-**object_and_items_nullable_prop** | **Dict[str, Optional[object]]** | | [optional]
-**object_items_nullable** | **Dict[str, Optional[object]]** | | [optional]
+**array_nullable_prop** | **list[object]** | | [optional]
+**array_and_items_nullable_prop** | **list[Optional[object]]** | | [optional]
+**array_items_nullable** | **list[Optional[object]]** | | [optional]
+**object_nullable_prop** | **dict[str, object]** | | [optional]
+**object_and_items_nullable_prop** | **dict[str, Optional[object]]** | | [optional]
+**object_items_nullable** | **dict[str, Optional[object]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/python/docs/ObjectWithDeprecatedFields.md
index 6dbd2ace04f1..fcdff0bdf060 100644
--- a/samples/openapi3/client/petstore/python/docs/ObjectWithDeprecatedFields.md
+++ b/samples/openapi3/client/petstore/python/docs/ObjectWithDeprecatedFields.md
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
**uuid** | **str** | | [optional]
**id** | **float** | | [optional]
**deprecated_ref** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional]
-**bars** | **List[str]** | | [optional]
+**bars** | **list[str]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/Parent.md b/samples/openapi3/client/petstore/python/docs/Parent.md
index 7387f9250aad..56fbac8cbb28 100644
--- a/samples/openapi3/client/petstore/python/docs/Parent.md
+++ b/samples/openapi3/client/petstore/python/docs/Parent.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/ParentWithOptionalDict.md b/samples/openapi3/client/petstore/python/docs/ParentWithOptionalDict.md
index bfc8688ea26f..7d278755c08f 100644
--- a/samples/openapi3/client/petstore/python/docs/ParentWithOptionalDict.md
+++ b/samples/openapi3/client/petstore/python/docs/ParentWithOptionalDict.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**optional_dict** | [**Dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
+**optional_dict** | [**dict[str, InnerDictWithProperty]**](InnerDictWithProperty.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/Pet.md b/samples/openapi3/client/petstore/python/docs/Pet.md
index 5329cf2fb925..14d1e224a08a 100644
--- a/samples/openapi3/client/petstore/python/docs/Pet.md
+++ b/samples/openapi3/client/petstore/python/docs/Pet.md
@@ -8,8 +8,8 @@ Name | Type | Description | Notes
**id** | **int** | | [optional]
**category** | [**Category**](Category.md) | | [optional]
**name** | **str** | |
-**photo_urls** | **List[str]** | |
-**tags** | [**List[Tag]**](Tag.md) | | [optional]
+**photo_urls** | **list[str]** | |
+**tags** | [**list[Tag]**](Tag.md) | | [optional]
**status** | **str** | pet status in the store | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/PetApi.md b/samples/openapi3/client/petstore/python/docs/PetApi.md
index 3396f1974f91..02e33e420dfc 100644
--- a/samples/openapi3/client/petstore/python/docs/PetApi.md
+++ b/samples/openapi3/client/petstore/python/docs/PetApi.md
@@ -228,7 +228,7 @@ void (empty response body)
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_status**
-> List[Pet] find_pets_by_status(status)
+> list[Pet] find_pets_by_status(status)
Finds Pets by status
@@ -324,7 +324,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- status = ['status_example'] # List[str] | Status values that need to be considered for filter
+ status = ['status_example'] # list[str] | Status values that need to be considered for filter
try:
# Finds Pets by status
@@ -342,11 +342,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **status** | [**List[str]**](str.md)| Status values that need to be considered for filter |
+ **status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
@@ -367,7 +367,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **find_pets_by_tags**
-> List[Pet] find_pets_by_tags(tags)
+> list[Pet] find_pets_by_tags(tags)
Finds Pets by tags
@@ -463,7 +463,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.PetApi(api_client)
- tags = ['tags_example'] # List[str] | Tags to filter by
+ tags = ['tags_example'] # list[str] | Tags to filter by
try:
# Finds Pets by tags
@@ -481,11 +481,11 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **tags** | [**List[str]**](str.md)| Tags to filter by |
+ **tags** | [**list[str]**](str.md)| Tags to filter by |
### Return type
-[**List[Pet]**](Pet.md)
+[**list[Pet]**](Pet.md)
### Authorization
diff --git a/samples/openapi3/client/petstore/python/docs/PropertyMap.md b/samples/openapi3/client/petstore/python/docs/PropertyMap.md
index a55a0e5c6f01..0c32115e8200 100644
--- a/samples/openapi3/client/petstore/python/docs/PropertyMap.md
+++ b/samples/openapi3/client/petstore/python/docs/PropertyMap.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**some_data** | [**Dict[str, Tag]**](Tag.md) | | [optional]
+**some_data** | [**dict[str, Tag]**](Tag.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/SecondCircularAllOfRef.md b/samples/openapi3/client/petstore/python/docs/SecondCircularAllOfRef.md
index 65ebdd4c7e1d..894564db2594 100644
--- a/samples/openapi3/client/petstore/python/docs/SecondCircularAllOfRef.md
+++ b/samples/openapi3/client/petstore/python/docs/SecondCircularAllOfRef.md
@@ -6,7 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | | [optional]
-**circular_all_of_ref** | [**List[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
+**circular_all_of_ref** | [**list[CircularAllOfRef]**](CircularAllOfRef.md) | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/StoreApi.md b/samples/openapi3/client/petstore/python/docs/StoreApi.md
index 19d6a89e5b9f..c719b75f2c84 100644
--- a/samples/openapi3/client/petstore/python/docs/StoreApi.md
+++ b/samples/openapi3/client/petstore/python/docs/StoreApi.md
@@ -77,7 +77,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **get_inventory**
-> Dict[str, int] get_inventory()
+> dict[str, int] get_inventory()
Returns pet inventories by status
@@ -131,7 +131,7 @@ This endpoint does not need any parameter.
### Return type
-**Dict[str, int]**
+**dict[str, int]**
### Authorization
diff --git a/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalModelListProperties.md b/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalModelListProperties.md
index 68cd00ab0a7a..dbf6ee475056 100644
--- a/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalModelListProperties.md
+++ b/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalModelListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[CreatureInfo]]** | | [optional]
+**dict_property** | **dict[str, list[CreatureInfo]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalStringListProperties.md b/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalStringListProperties.md
index 045b0e22ad09..f9bf8d7b3489 100644
--- a/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalStringListProperties.md
+++ b/samples/openapi3/client/petstore/python/docs/UnnamedDictWithAdditionalStringListProperties.md
@@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-**dict_property** | **Dict[str, List[str]]** | | [optional]
+**dict_property** | **dict[str, list[str]]** | | [optional]
## Example
diff --git a/samples/openapi3/client/petstore/python/docs/UserApi.md b/samples/openapi3/client/petstore/python/docs/UserApi.md
index a1e152924c0c..63cdc66d93c4 100644
--- a/samples/openapi3/client/petstore/python/docs/UserApi.md
+++ b/samples/openapi3/client/petstore/python/docs/UserApi.md
@@ -107,7 +107,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -123,7 +123,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
@@ -173,7 +173,7 @@ configuration = petstore_api.Configuration(
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = petstore_api.UserApi(api_client)
- user = [petstore_api.User()] # List[User] | List of user object
+ user = [petstore_api.User()] # list[User] | List of user object
try:
# Creates list of users with given input array
@@ -189,7 +189,7 @@ with petstore_api.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
- **user** | [**List[User]**](User.md)| List of user object |
+ **user** | [**list[User]**](User.md)| List of user object |
### Return type
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/another_fake_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/another_fake_api.py
index 56f2ab2cd1cd..b6ff53d1b760 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/another_fake_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/another_fake_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ def call_123_test_special_tags(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test special tags
@@ -90,7 +90,7 @@ def call_123_test_special_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -111,14 +111,14 @@ def call_123_test_special_tags_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test special tags
@@ -157,7 +157,7 @@ def call_123_test_special_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -178,14 +178,14 @@ def call_123_test_special_tags_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test special tags
@@ -224,7 +224,7 @@ def call_123_test_special_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -245,15 +245,15 @@ def _call_123_test_special_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _call_123_test_special_tags_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/default_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/default_api.py
index 2d007b2f26d3..32341443fd5c 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/default_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/default_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from petstore_api.models.foo_get_default_response import FooGetDefaultResponse
@@ -41,14 +41,14 @@ def foo_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> FooGetDefaultResponse:
"""foo_get
@@ -83,7 +83,7 @@ def foo_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -102,14 +102,14 @@ def foo_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[FooGetDefaultResponse]:
"""foo_get
@@ -144,7 +144,7 @@ def foo_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -163,14 +163,14 @@ def foo_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""foo_get
@@ -205,7 +205,7 @@ def foo_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -224,15 +224,15 @@ def _foo_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -253,7 +253,7 @@ def _foo_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/fake_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/fake_api.py
index 2373d1680c58..facaae5234fb 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/fake_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/fake_api.py
@@ -12,12 +12,12 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import date, datetime
from pydantic import Field, StrictBool, StrictBytes, StrictFloat, StrictInt, StrictStr, field_validator
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
from petstore_api.models.client import Client
@@ -56,18 +56,18 @@ def __init__(self, api_client=None) -> None:
@validate_call
def fake_any_type_request_body(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test any type request body
@@ -105,7 +105,7 @@ def fake_any_type_request_body(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -122,18 +122,18 @@ def fake_any_type_request_body(
@validate_call
def fake_any_type_request_body_with_http_info(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test any type request body
@@ -171,7 +171,7 @@ def fake_any_type_request_body_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -188,18 +188,18 @@ def fake_any_type_request_body_with_http_info(
@validate_call
def fake_any_type_request_body_without_preload_content(
self,
- body: Optional[Dict[str, Any]] = None,
+ body: Optional[dict[str, Any]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test any type request body
@@ -237,7 +237,7 @@ def fake_any_type_request_body_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -258,15 +258,15 @@ def _fake_any_type_request_body_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -295,7 +295,7 @@ def _fake_any_type_request_body_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -323,14 +323,14 @@ def fake_enum_ref_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test enum reference query parameter
@@ -368,7 +368,7 @@ def fake_enum_ref_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -389,14 +389,14 @@ def fake_enum_ref_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test enum reference query parameter
@@ -434,7 +434,7 @@ def fake_enum_ref_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -455,14 +455,14 @@ def fake_enum_ref_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum reference query parameter
@@ -500,7 +500,7 @@ def fake_enum_ref_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -521,15 +521,15 @@ def _fake_enum_ref_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -547,7 +547,7 @@ def _fake_enum_ref_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,14 +574,14 @@ def fake_health_get(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> HealthCheckResult:
"""Health check endpoint
@@ -616,7 +616,7 @@ def fake_health_get(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -636,14 +636,14 @@ def fake_health_get_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[HealthCheckResult]:
"""Health check endpoint
@@ -678,7 +678,7 @@ def fake_health_get_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -698,14 +698,14 @@ def fake_health_get_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Health check endpoint
@@ -740,7 +740,7 @@ def fake_health_get_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "HealthCheckResult",
}
response_data = self.api_client.call_api(
@@ -760,15 +760,15 @@ def _fake_health_get_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -789,7 +789,7 @@ def _fake_health_get_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -819,14 +819,14 @@ def fake_http_signature_test(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test http signature authentication
@@ -870,7 +870,7 @@ def fake_http_signature_test(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -893,14 +893,14 @@ def fake_http_signature_test_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test http signature authentication
@@ -944,7 +944,7 @@ def fake_http_signature_test_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -967,14 +967,14 @@ def fake_http_signature_test_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test http signature authentication
@@ -1018,7 +1018,7 @@ def fake_http_signature_test_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -1041,15 +1041,15 @@ def _fake_http_signature_test_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1085,7 +1085,7 @@ def _fake_http_signature_test_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_signature_test'
]
@@ -1114,14 +1114,14 @@ def fake_outer_boolean_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""fake_outer_boolean_serialize
@@ -1160,7 +1160,7 @@ def fake_outer_boolean_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1181,14 +1181,14 @@ def fake_outer_boolean_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""fake_outer_boolean_serialize
@@ -1227,7 +1227,7 @@ def fake_outer_boolean_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1248,14 +1248,14 @@ def fake_outer_boolean_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_boolean_serialize
@@ -1294,7 +1294,7 @@ def fake_outer_boolean_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -1315,15 +1315,15 @@ def _fake_outer_boolean_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1359,7 +1359,7 @@ def _fake_outer_boolean_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1387,14 +1387,14 @@ def fake_outer_composite_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterComposite:
"""fake_outer_composite_serialize
@@ -1433,7 +1433,7 @@ def fake_outer_composite_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1454,14 +1454,14 @@ def fake_outer_composite_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterComposite]:
"""fake_outer_composite_serialize
@@ -1500,7 +1500,7 @@ def fake_outer_composite_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1521,14 +1521,14 @@ def fake_outer_composite_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_composite_serialize
@@ -1567,7 +1567,7 @@ def fake_outer_composite_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterComposite",
}
response_data = self.api_client.call_api(
@@ -1588,15 +1588,15 @@ def _fake_outer_composite_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1632,7 +1632,7 @@ def _fake_outer_composite_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1660,14 +1660,14 @@ def fake_outer_number_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""fake_outer_number_serialize
@@ -1706,7 +1706,7 @@ def fake_outer_number_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1727,14 +1727,14 @@ def fake_outer_number_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""fake_outer_number_serialize
@@ -1773,7 +1773,7 @@ def fake_outer_number_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1794,14 +1794,14 @@ def fake_outer_number_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_number_serialize
@@ -1840,7 +1840,7 @@ def fake_outer_number_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -1861,15 +1861,15 @@ def _fake_outer_number_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1905,7 +1905,7 @@ def _fake_outer_number_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1933,14 +1933,14 @@ def fake_outer_string_serialize(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""fake_outer_string_serialize
@@ -1979,7 +1979,7 @@ def fake_outer_string_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2000,14 +2000,14 @@ def fake_outer_string_serialize_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""fake_outer_string_serialize
@@ -2046,7 +2046,7 @@ def fake_outer_string_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2067,14 +2067,14 @@ def fake_outer_string_serialize_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_outer_string_serialize
@@ -2113,7 +2113,7 @@ def fake_outer_string_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -2134,15 +2134,15 @@ def _fake_outer_string_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2178,7 +2178,7 @@ def _fake_outer_string_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2203,18 +2203,18 @@ def _fake_outer_string_serialize_serialize(
def fake_property_enum_integer_serialize(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> OuterObjectWithEnumProperty:
"""fake_property_enum_integer_serialize
@@ -2224,7 +2224,7 @@ def fake_property_enum_integer_serialize(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2256,7 +2256,7 @@ def fake_property_enum_integer_serialize(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2274,18 +2274,18 @@ def fake_property_enum_integer_serialize(
def fake_property_enum_integer_serialize_with_http_info(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[OuterObjectWithEnumProperty]:
"""fake_property_enum_integer_serialize
@@ -2295,7 +2295,7 @@ def fake_property_enum_integer_serialize_with_http_info(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2327,7 +2327,7 @@ def fake_property_enum_integer_serialize_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2345,18 +2345,18 @@ def fake_property_enum_integer_serialize_with_http_info(
def fake_property_enum_integer_serialize_without_preload_content(
self,
outer_object_with_enum_property: Annotated[OuterObjectWithEnumProperty, Field(description="Input enum (int) as post body")],
- param: Optional[List[OuterEnumInteger]] = None,
+ param: Optional[list[OuterEnumInteger]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""fake_property_enum_integer_serialize
@@ -2366,7 +2366,7 @@ def fake_property_enum_integer_serialize_without_preload_content(
:param outer_object_with_enum_property: Input enum (int) as post body (required)
:type outer_object_with_enum_property: OuterObjectWithEnumProperty
:param param:
- :type param: List[OuterEnumInteger]
+ :type param: list[OuterEnumInteger]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -2398,7 +2398,7 @@ def fake_property_enum_integer_serialize_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "OuterObjectWithEnumProperty",
}
response_data = self.api_client.call_api(
@@ -2420,16 +2420,16 @@ def _fake_property_enum_integer_serialize_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'param': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2469,7 +2469,7 @@ def _fake_property_enum_integer_serialize_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2496,14 +2496,14 @@ def fake_ref_enum_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> EnumClass:
"""test ref to enum string
@@ -2538,7 +2538,7 @@ def fake_ref_enum_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2558,14 +2558,14 @@ def fake_ref_enum_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[EnumClass]:
"""test ref to enum string
@@ -2600,7 +2600,7 @@ def fake_ref_enum_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2620,14 +2620,14 @@ def fake_ref_enum_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test ref to enum string
@@ -2662,7 +2662,7 @@ def fake_ref_enum_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "EnumClass",
}
response_data = self.api_client.call_api(
@@ -2682,15 +2682,15 @@ def _fake_ref_enum_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2711,7 +2711,7 @@ def _fake_ref_enum_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2738,14 +2738,14 @@ def fake_return_boolean(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bool:
"""test returning boolean
@@ -2780,7 +2780,7 @@ def fake_return_boolean(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2800,14 +2800,14 @@ def fake_return_boolean_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bool]:
"""test returning boolean
@@ -2842,7 +2842,7 @@ def fake_return_boolean_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2862,14 +2862,14 @@ def fake_return_boolean_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning boolean
@@ -2904,7 +2904,7 @@ def fake_return_boolean_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bool",
}
response_data = self.api_client.call_api(
@@ -2924,15 +2924,15 @@ def _fake_return_boolean_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2953,7 +2953,7 @@ def _fake_return_boolean_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -2980,14 +2980,14 @@ def fake_return_byte_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> bytes:
"""test byte like json
@@ -3022,7 +3022,7 @@ def fake_return_byte_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3042,14 +3042,14 @@ def fake_return_byte_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[bytes]:
"""test byte like json
@@ -3084,7 +3084,7 @@ def fake_return_byte_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3104,14 +3104,14 @@ def fake_return_byte_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test byte like json
@@ -3146,7 +3146,7 @@ def fake_return_byte_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "bytes",
}
response_data = self.api_client.call_api(
@@ -3166,15 +3166,15 @@ def _fake_return_byte_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3195,7 +3195,7 @@ def _fake_return_byte_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3222,14 +3222,14 @@ def fake_return_enum(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning enum
@@ -3264,7 +3264,7 @@ def fake_return_enum(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3284,14 +3284,14 @@ def fake_return_enum_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning enum
@@ -3326,7 +3326,7 @@ def fake_return_enum_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3346,14 +3346,14 @@ def fake_return_enum_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning enum
@@ -3388,7 +3388,7 @@ def fake_return_enum_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3408,15 +3408,15 @@ def _fake_return_enum_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3437,7 +3437,7 @@ def _fake_return_enum_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3464,14 +3464,14 @@ def fake_return_enum_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test enum like json
@@ -3506,7 +3506,7 @@ def fake_return_enum_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3526,14 +3526,14 @@ def fake_return_enum_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test enum like json
@@ -3568,7 +3568,7 @@ def fake_return_enum_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3588,14 +3588,14 @@ def fake_return_enum_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test enum like json
@@ -3630,7 +3630,7 @@ def fake_return_enum_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -3650,15 +3650,15 @@ def _fake_return_enum_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3679,7 +3679,7 @@ def _fake_return_enum_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3706,14 +3706,14 @@ def fake_return_float(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> float:
"""test returning float
@@ -3748,7 +3748,7 @@ def fake_return_float(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3768,14 +3768,14 @@ def fake_return_float_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[float]:
"""test returning float
@@ -3810,7 +3810,7 @@ def fake_return_float_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3830,14 +3830,14 @@ def fake_return_float_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning float
@@ -3872,7 +3872,7 @@ def fake_return_float_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "float",
}
response_data = self.api_client.call_api(
@@ -3892,15 +3892,15 @@ def _fake_return_float_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -3921,7 +3921,7 @@ def _fake_return_float_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -3948,14 +3948,14 @@ def fake_return_int(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> int:
"""test returning int
@@ -3990,7 +3990,7 @@ def fake_return_int(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4010,14 +4010,14 @@ def fake_return_int_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[int]:
"""test returning int
@@ -4052,7 +4052,7 @@ def fake_return_int_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4072,14 +4072,14 @@ def fake_return_int_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning int
@@ -4114,7 +4114,7 @@ def fake_return_int_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "int",
}
response_data = self.api_client.call_api(
@@ -4134,15 +4134,15 @@ def _fake_return_int_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4163,7 +4163,7 @@ def _fake_return_int_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4190,16 +4190,16 @@ def fake_return_list_of_objects(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[List[Tag]]:
+ ) -> list[list[Tag]]:
"""test returning list of objects
@@ -4232,8 +4232,8 @@ def fake_return_list_of_objects(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4252,16 +4252,16 @@ def fake_return_list_of_objects_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[List[Tag]]]:
+ ) -> ApiResponse[list[list[Tag]]]:
"""test returning list of objects
@@ -4294,8 +4294,8 @@ def fake_return_list_of_objects_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4314,14 +4314,14 @@ def fake_return_list_of_objects_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning list of objects
@@ -4356,8 +4356,8 @@ def fake_return_list_of_objects_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[List[Tag]]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[list[Tag]]",
}
response_data = self.api_client.call_api(
*_param,
@@ -4376,15 +4376,15 @@ def _fake_return_list_of_objects_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4405,7 +4405,7 @@ def _fake_return_list_of_objects_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4432,14 +4432,14 @@ def fake_return_str_like_json(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test str like json
@@ -4474,7 +4474,7 @@ def fake_return_str_like_json(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4494,14 +4494,14 @@ def fake_return_str_like_json_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test str like json
@@ -4536,7 +4536,7 @@ def fake_return_str_like_json_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4556,14 +4556,14 @@ def fake_return_str_like_json_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test str like json
@@ -4598,7 +4598,7 @@ def fake_return_str_like_json_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4618,15 +4618,15 @@ def _fake_return_str_like_json_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4647,7 +4647,7 @@ def _fake_return_str_like_json_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4674,14 +4674,14 @@ def fake_return_string(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""test returning string
@@ -4716,7 +4716,7 @@ def fake_return_string(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4736,14 +4736,14 @@ def fake_return_string_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""test returning string
@@ -4778,7 +4778,7 @@ def fake_return_string_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4798,14 +4798,14 @@ def fake_return_string_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test returning string
@@ -4840,7 +4840,7 @@ def fake_return_string_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
}
response_data = self.api_client.call_api(
@@ -4860,15 +4860,15 @@ def _fake_return_string_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -4889,7 +4889,7 @@ def _fake_return_string_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -4917,14 +4917,14 @@ def fake_uuid_example(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test uuid example
@@ -4962,7 +4962,7 @@ def fake_uuid_example(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -4983,14 +4983,14 @@ def fake_uuid_example_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test uuid example
@@ -5028,7 +5028,7 @@ def fake_uuid_example_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5049,14 +5049,14 @@ def fake_uuid_example_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test uuid example
@@ -5094,7 +5094,7 @@ def fake_uuid_example_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5115,15 +5115,15 @@ def _fake_uuid_example_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5141,7 +5141,7 @@ def _fake_uuid_example_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5165,18 +5165,18 @@ def _fake_uuid_example_serialize(
@validate_call
def test_additional_properties_reference(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced additionalProperties
@@ -5184,7 +5184,7 @@ def test_additional_properties_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5215,7 +5215,7 @@ def test_additional_properties_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5232,18 +5232,18 @@ def test_additional_properties_reference(
@validate_call
def test_additional_properties_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced additionalProperties
@@ -5251,7 +5251,7 @@ def test_additional_properties_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5282,7 +5282,7 @@ def test_additional_properties_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5299,18 +5299,18 @@ def test_additional_properties_reference_with_http_info(
@validate_call
def test_additional_properties_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, Any], Field(description="request body")],
+ request_body: Annotated[dict[str, Any], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced additionalProperties
@@ -5318,7 +5318,7 @@ def test_additional_properties_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, object]
+ :type request_body: dict[str, object]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -5349,7 +5349,7 @@ def test_additional_properties_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5370,15 +5370,15 @@ def _test_additional_properties_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5407,7 +5407,7 @@ def _test_additional_properties_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5431,18 +5431,18 @@ def _test_additional_properties_reference_serialize(
@validate_call
def test_body_with_binary(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_binary
@@ -5481,7 +5481,7 @@ def test_body_with_binary(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5498,18 +5498,18 @@ def test_body_with_binary(
@validate_call
def test_body_with_binary_with_http_info(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_binary
@@ -5548,7 +5548,7 @@ def test_body_with_binary_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5565,18 +5565,18 @@ def test_body_with_binary_with_http_info(
@validate_call
def test_body_with_binary_without_preload_content(
self,
- body: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
+ body: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="image to upload")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_binary
@@ -5615,7 +5615,7 @@ def test_body_with_binary_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5636,15 +5636,15 @@ def _test_body_with_binary_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5681,7 +5681,7 @@ def _test_body_with_binary_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5709,14 +5709,14 @@ def test_body_with_file_schema(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_file_schema
@@ -5755,7 +5755,7 @@ def test_body_with_file_schema(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5776,14 +5776,14 @@ def test_body_with_file_schema_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_file_schema
@@ -5822,7 +5822,7 @@ def test_body_with_file_schema_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5843,14 +5843,14 @@ def test_body_with_file_schema_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_file_schema
@@ -5889,7 +5889,7 @@ def test_body_with_file_schema_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -5910,15 +5910,15 @@ def _test_body_with_file_schema_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -5947,7 +5947,7 @@ def _test_body_with_file_schema_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -5976,14 +5976,14 @@ def test_body_with_query_params(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_body_with_query_params
@@ -6024,7 +6024,7 @@ def test_body_with_query_params(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6046,14 +6046,14 @@ def test_body_with_query_params_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_body_with_query_params
@@ -6094,7 +6094,7 @@ def test_body_with_query_params_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6116,14 +6116,14 @@ def test_body_with_query_params_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_body_with_query_params
@@ -6164,7 +6164,7 @@ def test_body_with_query_params_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6186,15 +6186,15 @@ def _test_body_with_query_params_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6227,7 +6227,7 @@ def _test_body_with_query_params_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6255,14 +6255,14 @@ def test_client_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test \"client\" model
@@ -6301,7 +6301,7 @@ def test_client_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6322,14 +6322,14 @@ def test_client_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test \"client\" model
@@ -6368,7 +6368,7 @@ def test_client_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6389,14 +6389,14 @@ def test_client_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test \"client\" model
@@ -6435,7 +6435,7 @@ def test_client_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -6456,15 +6456,15 @@ def _test_client_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6500,7 +6500,7 @@ def _test_client_model_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6529,14 +6529,14 @@ def test_date_time_query_parameter(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_date_time_query_parameter
@@ -6577,7 +6577,7 @@ def test_date_time_query_parameter(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6599,14 +6599,14 @@ def test_date_time_query_parameter_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_date_time_query_parameter
@@ -6647,7 +6647,7 @@ def test_date_time_query_parameter_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6669,14 +6669,14 @@ def test_date_time_query_parameter_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_date_time_query_parameter
@@ -6717,7 +6717,7 @@ def test_date_time_query_parameter_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -6739,15 +6739,15 @@ def _test_date_time_query_parameter_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -6778,7 +6778,7 @@ def _test_date_time_query_parameter_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -6805,14 +6805,14 @@ def test_empty_and_non_empty_responses(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test empty and non-empty responses
@@ -6848,7 +6848,7 @@ def test_empty_and_non_empty_responses(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6869,14 +6869,14 @@ def test_empty_and_non_empty_responses_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test empty and non-empty responses
@@ -6912,7 +6912,7 @@ def test_empty_and_non_empty_responses_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6933,14 +6933,14 @@ def test_empty_and_non_empty_responses_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test empty and non-empty responses
@@ -6976,7 +6976,7 @@ def test_empty_and_non_empty_responses_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'206': "str",
}
@@ -6997,15 +6997,15 @@ def _test_empty_and_non_empty_responses_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7026,7 +7026,7 @@ def _test_empty_and_non_empty_responses_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7059,7 +7059,7 @@ def test_endpoint_parameters(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7068,14 +7068,14 @@ def test_endpoint_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7156,7 +7156,7 @@ def test_endpoint_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7183,7 +7183,7 @@ def test_endpoint_parameters_with_http_info(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7192,14 +7192,14 @@ def test_endpoint_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7280,7 +7280,7 @@ def test_endpoint_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7307,7 +7307,7 @@ def test_endpoint_parameters_without_preload_content(
int64: Annotated[Optional[StrictInt], Field(description="None")] = None,
var_float: Annotated[Optional[Annotated[float, Field(le=987.6, strict=True)]], Field(description="None")] = None,
string: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="None")] = None,
- binary: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
+ binary: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="None")] = None,
byte_with_max_length: Annotated[Optional[Union[Annotated[bytes, Field(strict=True, max_length=64)], Annotated[str, Field(strict=True, max_length=64)]]], Field(description="None")] = None,
var_date: Annotated[Optional[date], Field(description="None")] = None,
date_time: Annotated[Optional[datetime], Field(description="None")] = None,
@@ -7316,14 +7316,14 @@ def test_endpoint_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
@@ -7404,7 +7404,7 @@ def test_endpoint_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -7440,15 +7440,15 @@ def _test_endpoint_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7505,7 +7505,7 @@ def _test_endpoint_parameters_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'http_basic_test'
]
@@ -7533,14 +7533,14 @@ def test_error_responses_with_model(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test error responses with model
@@ -7575,7 +7575,7 @@ def test_error_responses_with_model(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7597,14 +7597,14 @@ def test_error_responses_with_model_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test error responses with model
@@ -7639,7 +7639,7 @@ def test_error_responses_with_model_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7661,14 +7661,14 @@ def test_error_responses_with_model_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test error responses with model
@@ -7703,7 +7703,7 @@ def test_error_responses_with_model_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'204': None,
'400': "TestErrorResponsesWithModel400Response",
'404': "TestErrorResponsesWithModel404Response",
@@ -7725,15 +7725,15 @@ def _test_error_responses_with_model_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -7754,7 +7754,7 @@ def _test_error_responses_with_model_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -7787,14 +7787,14 @@ def test_group_parameters(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Fake endpoint to test group parameters (optional)
@@ -7848,7 +7848,7 @@ def test_group_parameters(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -7874,14 +7874,14 @@ def test_group_parameters_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Fake endpoint to test group parameters (optional)
@@ -7935,7 +7935,7 @@ def test_group_parameters_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -7961,14 +7961,14 @@ def test_group_parameters_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Fake endpoint to test group parameters (optional)
@@ -8022,7 +8022,7 @@ def test_group_parameters_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
}
response_data = self.api_client.call_api(
@@ -8048,15 +8048,15 @@ def _test_group_parameters_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8090,7 +8090,7 @@ def _test_group_parameters_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'bearer_test'
]
@@ -8115,18 +8115,18 @@ def _test_group_parameters_serialize(
@validate_call
def test_inline_additional_properties(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline additionalProperties
@@ -8134,7 +8134,7 @@ def test_inline_additional_properties(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8165,7 +8165,7 @@ def test_inline_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8182,18 +8182,18 @@ def test_inline_additional_properties(
@validate_call
def test_inline_additional_properties_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline additionalProperties
@@ -8201,7 +8201,7 @@ def test_inline_additional_properties_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8232,7 +8232,7 @@ def test_inline_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8249,18 +8249,18 @@ def test_inline_additional_properties_with_http_info(
@validate_call
def test_inline_additional_properties_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline additionalProperties
@@ -8268,7 +8268,7 @@ def test_inline_additional_properties_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -8299,7 +8299,7 @@ def test_inline_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8320,15 +8320,15 @@ def _test_inline_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8357,7 +8357,7 @@ def _test_inline_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8385,14 +8385,14 @@ def test_inline_freeform_additional_properties(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test inline free-form additionalProperties
@@ -8431,7 +8431,7 @@ def test_inline_freeform_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8452,14 +8452,14 @@ def test_inline_freeform_additional_properties_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test inline free-form additionalProperties
@@ -8498,7 +8498,7 @@ def test_inline_freeform_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8519,14 +8519,14 @@ def test_inline_freeform_additional_properties_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test inline free-form additionalProperties
@@ -8565,7 +8565,7 @@ def test_inline_freeform_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8586,15 +8586,15 @@ def _test_inline_freeform_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8623,7 +8623,7 @@ def _test_inline_freeform_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8652,14 +8652,14 @@ def test_json_form_data(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test json serialization of form data
@@ -8701,7 +8701,7 @@ def test_json_form_data(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8723,14 +8723,14 @@ def test_json_form_data_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test json serialization of form data
@@ -8772,7 +8772,7 @@ def test_json_form_data_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8794,14 +8794,14 @@ def test_json_form_data_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test json serialization of form data
@@ -8843,7 +8843,7 @@ def test_json_form_data_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8865,15 +8865,15 @@ def _test_json_form_data_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -8904,7 +8904,7 @@ def _test_json_form_data_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -8932,14 +8932,14 @@ def test_object_for_multipart_requests(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_object_for_multipart_requests
@@ -8977,7 +8977,7 @@ def test_object_for_multipart_requests(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -8998,14 +8998,14 @@ def test_object_for_multipart_requests_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_object_for_multipart_requests
@@ -9043,7 +9043,7 @@ def test_object_for_multipart_requests_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9064,14 +9064,14 @@ def test_object_for_multipart_requests_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_object_for_multipart_requests
@@ -9109,7 +9109,7 @@ def test_object_for_multipart_requests_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9130,15 +9130,15 @@ def _test_object_for_multipart_requests_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9167,7 +9167,7 @@ def _test_object_for_multipart_requests_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9191,24 +9191,24 @@ def _test_object_for_multipart_requests_serialize(
@validate_call
def test_query_parameter_collection_format(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test_query_parameter_collection_format
@@ -9216,19 +9216,19 @@ def test_query_parameter_collection_format(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9265,7 +9265,7 @@ def test_query_parameter_collection_format(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9282,24 +9282,24 @@ def test_query_parameter_collection_format(
@validate_call
def test_query_parameter_collection_format_with_http_info(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test_query_parameter_collection_format
@@ -9307,19 +9307,19 @@ def test_query_parameter_collection_format_with_http_info(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9356,7 +9356,7 @@ def test_query_parameter_collection_format_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9373,24 +9373,24 @@ def test_query_parameter_collection_format_with_http_info(
@validate_call
def test_query_parameter_collection_format_without_preload_content(
self,
- pipe: List[StrictStr],
- ioutil: List[StrictStr],
- http: List[StrictStr],
- url: List[StrictStr],
- context: List[StrictStr],
+ pipe: list[StrictStr],
+ ioutil: list[StrictStr],
+ http: list[StrictStr],
+ url: list[StrictStr],
+ context: list[StrictStr],
allow_empty: StrictStr,
- language: Optional[Dict[str, StrictStr]] = None,
+ language: Optional[dict[str, StrictStr]] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test_query_parameter_collection_format
@@ -9398,19 +9398,19 @@ def test_query_parameter_collection_format_without_preload_content(
To test the collection format in query parameters
:param pipe: (required)
- :type pipe: List[str]
+ :type pipe: list[str]
:param ioutil: (required)
- :type ioutil: List[str]
+ :type ioutil: list[str]
:param http: (required)
- :type http: List[str]
+ :type http: list[str]
:param url: (required)
- :type url: List[str]
+ :type url: list[str]
:param context: (required)
- :type context: List[str]
+ :type context: list[str]
:param allow_empty: (required)
:type allow_empty: str
:param language:
- :type language: Dict[str, str]
+ :type language: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9447,7 +9447,7 @@ def test_query_parameter_collection_format_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9474,7 +9474,7 @@ def _test_query_parameter_collection_format_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'pipe': 'pipes',
'ioutil': 'csv',
'http': 'ssv',
@@ -9482,12 +9482,12 @@ def _test_query_parameter_collection_format_serialize(
'context': 'multi',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9529,7 +9529,7 @@ def _test_query_parameter_collection_format_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9553,18 +9553,18 @@ def _test_query_parameter_collection_format_serialize(
@validate_call
def test_string_map_reference(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""test referenced string map
@@ -9572,7 +9572,7 @@ def test_string_map_reference(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9603,7 +9603,7 @@ def test_string_map_reference(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9620,18 +9620,18 @@ def test_string_map_reference(
@validate_call
def test_string_map_reference_with_http_info(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""test referenced string map
@@ -9639,7 +9639,7 @@ def test_string_map_reference_with_http_info(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9670,7 +9670,7 @@ def test_string_map_reference_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9687,18 +9687,18 @@ def test_string_map_reference_with_http_info(
@validate_call
def test_string_map_reference_without_preload_content(
self,
- request_body: Annotated[Dict[str, StrictStr], Field(description="request body")],
+ request_body: Annotated[dict[str, StrictStr], Field(description="request body")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test referenced string map
@@ -9706,7 +9706,7 @@ def test_string_map_reference_without_preload_content(
:param request_body: request body (required)
- :type request_body: Dict[str, str]
+ :type request_body: dict[str, str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -9737,7 +9737,7 @@ def test_string_map_reference_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
}
response_data = self.api_client.call_api(
@@ -9758,15 +9758,15 @@ def _test_string_map_reference_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -9795,7 +9795,7 @@ def _test_string_map_reference_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -9819,20 +9819,20 @@ def _test_string_map_reference_serialize(
@validate_call
def upload_file_with_additional_properties(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads a file and additional properties using multipart/form-data
@@ -9877,7 +9877,7 @@ def upload_file_with_additional_properties(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -9894,20 +9894,20 @@ def upload_file_with_additional_properties(
@validate_call
def upload_file_with_additional_properties_with_http_info(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads a file and additional properties using multipart/form-data
@@ -9952,7 +9952,7 @@ def upload_file_with_additional_properties_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -9969,20 +9969,20 @@ def upload_file_with_additional_properties_with_http_info(
@validate_call
def upload_file_with_additional_properties_without_preload_content(
self,
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
object: Optional[UploadFileWithAdditionalPropertiesRequestObject] = None,
count: Annotated[Optional[StrictInt], Field(description="Integer count")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads a file and additional properties using multipart/form-data
@@ -10027,7 +10027,7 @@ def upload_file_with_additional_properties_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -10050,15 +10050,15 @@ def _upload_file_with_additional_properties_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -10098,7 +10098,7 @@ def _upload_file_with_additional_properties_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/fake_classname_tags123_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/fake_classname_tags123_api.py
index e373462e5f5b..1aa861478c09 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/api/fake_classname_tags123_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/fake_classname_tags123_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field
@@ -44,14 +44,14 @@ def test_classname(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Client:
"""To test class name in snake case
@@ -90,7 +90,7 @@ def test_classname(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -111,14 +111,14 @@ def test_classname_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Client]:
"""To test class name in snake case
@@ -157,7 +157,7 @@ def test_classname_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -178,14 +178,14 @@ def test_classname_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""To test class name in snake case
@@ -224,7 +224,7 @@ def test_classname_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Client",
}
response_data = self.api_client.call_api(
@@ -245,15 +245,15 @@ def _test_classname_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -289,7 +289,7 @@ def _test_classname_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key_query'
]
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/import_test_datetime_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/import_test_datetime_api.py
index ae01fa137fa1..25dcb6578520 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/api/import_test_datetime_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/import_test_datetime_api.py
@@ -12,7 +12,7 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from datetime import datetime
@@ -41,14 +41,14 @@ def import_test_return_datetime(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> datetime:
"""test date time
@@ -83,7 +83,7 @@ def import_test_return_datetime(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -103,14 +103,14 @@ def import_test_return_datetime_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[datetime]:
"""test date time
@@ -145,7 +145,7 @@ def import_test_return_datetime_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -165,14 +165,14 @@ def import_test_return_datetime_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""test date time
@@ -207,7 +207,7 @@ def import_test_return_datetime_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "datetime",
}
response_data = self.api_client.call_api(
@@ -227,15 +227,15 @@ def _import_test_return_datetime_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -256,7 +256,7 @@ def _import_test_return_datetime_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/pet_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/pet_api.py
index 7d4cf604eb15..3e24a847941f 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/pet_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/pet_api.py
@@ -12,11 +12,11 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import List, Optional, Tuple, Union
+from typing import Optional, Union
from typing_extensions import Annotated
from petstore_api.models.model_api_response import ModelApiResponse
from petstore_api.models.pet import Pet
@@ -46,14 +46,14 @@ def add_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Add a new pet to the store
@@ -92,7 +92,7 @@ def add_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -114,14 +114,14 @@ def add_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Add a new pet to the store
@@ -160,7 +160,7 @@ def add_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -182,14 +182,14 @@ def add_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Add a new pet to the store
@@ -228,7 +228,7 @@ def add_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -250,15 +250,15 @@ def _add_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -288,7 +288,7 @@ def _add_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -319,14 +319,14 @@ def delete_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Deletes a pet
@@ -368,7 +368,7 @@ def delete_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -391,14 +391,14 @@ def delete_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Deletes a pet
@@ -440,7 +440,7 @@ def delete_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -463,14 +463,14 @@ def delete_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Deletes a pet
@@ -512,7 +512,7 @@ def delete_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
}
@@ -535,15 +535,15 @@ def _delete_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -561,7 +561,7 @@ def _delete_pet_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -586,26 +586,26 @@ def _delete_pet_serialize(
@validate_call
def find_pets_by_status(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -636,8 +636,8 @@ def find_pets_by_status(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -654,26 +654,26 @@ def find_pets_by_status(
@validate_call
def find_pets_by_status_with_http_info(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""Finds Pets by status
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -704,8 +704,8 @@ def find_pets_by_status_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -722,18 +722,18 @@ def find_pets_by_status_with_http_info(
@validate_call
def find_pets_by_status_without_preload_content(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Finds Pets by status
@@ -741,7 +741,7 @@ def find_pets_by_status_without_preload_content(
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter (required)
- :type status: List[str]
+ :type status: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -772,8 +772,8 @@ def find_pets_by_status_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -794,16 +794,16 @@ def _find_pets_by_status_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'status': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -829,7 +829,7 @@ def _find_pets_by_status_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -855,26 +855,26 @@ def _find_pets_by_status_serialize(
@validate_call
def find_pets_by_tags(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> List[Pet]:
+ ) -> list[Pet]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -906,8 +906,8 @@ def find_pets_by_tags(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -924,26 +924,26 @@ def find_pets_by_tags(
@validate_call
def find_pets_by_tags_with_http_info(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[List[Pet]]:
+ ) -> ApiResponse[list[Pet]]:
"""(Deprecated) Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -975,8 +975,8 @@ def find_pets_by_tags_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -993,18 +993,18 @@ def find_pets_by_tags_with_http_info(
@validate_call
def find_pets_by_tags_without_preload_content(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""(Deprecated) Finds Pets by tags
@@ -1012,7 +1012,7 @@ def find_pets_by_tags_without_preload_content(
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by (required)
- :type tags: List[str]
+ :type tags: list[str]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -1044,8 +1044,8 @@ def find_pets_by_tags_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "List[Pet]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "list[Pet]",
'400': None,
}
response_data = self.api_client.call_api(
@@ -1066,16 +1066,16 @@ def _find_pets_by_tags_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'tags': 'csv',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1101,7 +1101,7 @@ def _find_pets_by_tags_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1131,14 +1131,14 @@ def get_pet_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Pet:
"""Find pet by ID
@@ -1177,7 +1177,7 @@ def get_pet_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1200,14 +1200,14 @@ def get_pet_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Pet]:
"""Find pet by ID
@@ -1246,7 +1246,7 @@ def get_pet_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1269,14 +1269,14 @@ def get_pet_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find pet by ID
@@ -1315,7 +1315,7 @@ def get_pet_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Pet",
'400': None,
'404': None,
@@ -1338,15 +1338,15 @@ def _get_pet_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1370,7 +1370,7 @@ def _get_pet_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -1399,14 +1399,14 @@ def update_pet(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Update an existing pet
@@ -1445,7 +1445,7 @@ def update_pet(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1469,14 +1469,14 @@ def update_pet_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Update an existing pet
@@ -1515,7 +1515,7 @@ def update_pet_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1539,14 +1539,14 @@ def update_pet_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Update an existing pet
@@ -1585,7 +1585,7 @@ def update_pet_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'400': None,
'404': None,
@@ -1609,15 +1609,15 @@ def _update_pet_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1647,7 +1647,7 @@ def _update_pet_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth',
'http_signature_test'
]
@@ -1679,14 +1679,14 @@ def update_pet_with_form(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updates a pet in the store with form data
@@ -1731,7 +1731,7 @@ def update_pet_with_form(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1755,14 +1755,14 @@ def update_pet_with_form_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updates a pet in the store with form data
@@ -1807,7 +1807,7 @@ def update_pet_with_form_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1831,14 +1831,14 @@ def update_pet_with_form_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updates a pet in the store with form data
@@ -1883,7 +1883,7 @@ def update_pet_with_form_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': None,
'405': None,
}
@@ -1907,15 +1907,15 @@ def _update_pet_with_form_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1948,7 +1948,7 @@ def _update_pet_with_form_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -1975,18 +1975,18 @@ def upload_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image
@@ -2031,7 +2031,7 @@ def upload_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2050,18 +2050,18 @@ def upload_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image
@@ -2106,7 +2106,7 @@ def upload_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2125,18 +2125,18 @@ def upload_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image
@@ -2181,7 +2181,7 @@ def upload_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2204,15 +2204,15 @@ def _upload_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2252,7 +2252,7 @@ def _upload_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
@@ -2278,19 +2278,19 @@ def _upload_file_serialize(
def upload_file_with_required_file(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ModelApiResponse:
"""uploads an image (required)
@@ -2335,7 +2335,7 @@ def upload_file_with_required_file(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2353,19 +2353,19 @@ def upload_file_with_required_file(
def upload_file_with_required_file_with_http_info(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[ModelApiResponse]:
"""uploads an image (required)
@@ -2410,7 +2410,7 @@ def upload_file_with_required_file_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2428,19 +2428,19 @@ def upload_file_with_required_file_with_http_info(
def upload_file_with_required_file_without_preload_content(
self,
pet_id: Annotated[StrictInt, Field(description="ID of pet to update")],
- required_file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
+ required_file: Annotated[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]], Field(description="file to upload")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = None,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""uploads an image (required)
@@ -2485,7 +2485,7 @@ def upload_file_with_required_file_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "ModelApiResponse",
}
response_data = self.api_client.call_api(
@@ -2508,15 +2508,15 @@ def _upload_file_with_required_file_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2556,7 +2556,7 @@ def _upload_file_with_required_file_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'petstore_auth'
]
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/store_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/store_api.py
index 73471217df00..d45fa277efb8 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/store_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/store_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictInt, StrictStr
-from typing import Dict
from typing_extensions import Annotated
from petstore_api.models.order import Order
@@ -45,14 +44,14 @@ def delete_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete purchase order by ID
@@ -91,7 +90,7 @@ def delete_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -113,14 +112,14 @@ def delete_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete purchase order by ID
@@ -159,7 +158,7 @@ def delete_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -181,14 +180,14 @@ def delete_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete purchase order by ID
@@ -227,7 +226,7 @@ def delete_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -249,15 +248,15 @@ def _delete_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -273,7 +272,7 @@ def _delete_order_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -300,16 +299,16 @@ def get_inventory(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> Dict[str, int]:
+ ) -> dict[str, int]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -343,8 +342,8 @@ def get_inventory(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -363,16 +362,16 @@ def get_inventory_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
- ) -> ApiResponse[Dict[str, int]]:
+ ) -> ApiResponse[dict[str, int]]:
"""Returns pet inventories by status
Returns a map of status codes to quantities
@@ -406,8 +405,8 @@ def get_inventory_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -426,14 +425,14 @@ def get_inventory_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Returns pet inventories by status
@@ -469,8 +468,8 @@ def get_inventory_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
- '200': "Dict[str, int]",
+ _response_types_map: dict[str, Optional[str]] = {
+ '200': "dict[str, int]",
}
response_data = self.api_client.call_api(
*_param,
@@ -489,15 +488,15 @@ def _get_inventory_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -518,7 +517,7 @@ def _get_inventory_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
'api_key'
]
@@ -547,14 +546,14 @@ def get_order_by_id(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Find purchase order by ID
@@ -593,7 +592,7 @@ def get_order_by_id(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -616,14 +615,14 @@ def get_order_by_id_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Find purchase order by ID
@@ -662,7 +661,7 @@ def get_order_by_id_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -685,14 +684,14 @@ def get_order_by_id_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Find purchase order by ID
@@ -731,7 +730,7 @@ def get_order_by_id_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
'404': None,
@@ -754,15 +753,15 @@ def _get_order_by_id_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -786,7 +785,7 @@ def _get_order_by_id_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -814,14 +813,14 @@ def place_order(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> Order:
"""Place an order for a pet
@@ -860,7 +859,7 @@ def place_order(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -882,14 +881,14 @@ def place_order_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[Order]:
"""Place an order for a pet
@@ -928,7 +927,7 @@ def place_order_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -950,14 +949,14 @@ def place_order_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Place an order for a pet
@@ -996,7 +995,7 @@ def place_order_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "Order",
'400': None,
}
@@ -1018,15 +1017,15 @@ def _place_order_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1063,7 +1062,7 @@ def _place_order_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api/user_api.py b/samples/openapi3/client/petstore/python/petstore_api/api/user_api.py
index be61d536e31c..b1c924343f6b 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api/user_api.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api/user_api.py
@@ -12,11 +12,10 @@
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
-from typing import Any, Dict, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from pydantic import Field, StrictStr
-from typing import List
from typing_extensions import Annotated
from petstore_api.models.user import User
@@ -45,14 +44,14 @@ def create_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> None:
"""Create user
@@ -91,7 +90,7 @@ def create_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -111,14 +110,14 @@ def create_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> ApiResponse[None]:
"""Create user
@@ -157,7 +156,7 @@ def create_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -177,14 +176,14 @@ def create_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=4)] = 0,
) -> RESTResponseType:
"""Create user
@@ -223,7 +222,7 @@ def create_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -249,15 +248,15 @@ def _create_user_serialize(
]
_host = _hosts[_host_index]
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -286,7 +285,7 @@ def _create_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -310,18 +309,18 @@ def _create_user_serialize(
@validate_call
def create_users_with_array_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -329,7 +328,7 @@ def create_users_with_array_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -360,7 +359,7 @@ def create_users_with_array_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -376,18 +375,18 @@ def create_users_with_array_input(
@validate_call
def create_users_with_array_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -395,7 +394,7 @@ def create_users_with_array_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -426,7 +425,7 @@ def create_users_with_array_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -442,18 +441,18 @@ def create_users_with_array_input_with_http_info(
@validate_call
def create_users_with_array_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -461,7 +460,7 @@ def create_users_with_array_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -492,7 +491,7 @@ def create_users_with_array_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -512,16 +511,16 @@ def _create_users_with_array_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -550,7 +549,7 @@ def _create_users_with_array_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -574,18 +573,18 @@ def _create_users_with_array_input_serialize(
@validate_call
def create_users_with_list_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Creates list of users with given input array
@@ -593,7 +592,7 @@ def create_users_with_list_input(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -624,7 +623,7 @@ def create_users_with_list_input(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -640,18 +639,18 @@ def create_users_with_list_input(
@validate_call
def create_users_with_list_input_with_http_info(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Creates list of users with given input array
@@ -659,7 +658,7 @@ def create_users_with_list_input_with_http_info(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -690,7 +689,7 @@ def create_users_with_list_input_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -706,18 +705,18 @@ def create_users_with_list_input_with_http_info(
@validate_call
def create_users_with_list_input_without_preload_content(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Creates list of users with given input array
@@ -725,7 +724,7 @@ def create_users_with_list_input_without_preload_content(
:param user: List of user object (required)
- :type user: List[User]
+ :type user: list[User]
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
@@ -756,7 +755,7 @@ def create_users_with_list_input_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -776,16 +775,16 @@ def _create_users_with_list_input_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
'User': '',
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -814,7 +813,7 @@ def _create_users_with_list_input_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -842,14 +841,14 @@ def delete_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Delete user
@@ -888,7 +887,7 @@ def delete_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -910,14 +909,14 @@ def delete_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Delete user
@@ -956,7 +955,7 @@ def delete_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -978,14 +977,14 @@ def delete_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Delete user
@@ -1024,7 +1023,7 @@ def delete_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1046,15 +1045,15 @@ def _delete_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1070,7 +1069,7 @@ def _delete_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1098,14 +1097,14 @@ def get_user_by_name(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> User:
"""Get user by user name
@@ -1144,7 +1143,7 @@ def get_user_by_name(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1167,14 +1166,14 @@ def get_user_by_name_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[User]:
"""Get user by user name
@@ -1213,7 +1212,7 @@ def get_user_by_name_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1236,14 +1235,14 @@ def get_user_by_name_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Get user by user name
@@ -1282,7 +1281,7 @@ def get_user_by_name_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "User",
'400': None,
'404': None,
@@ -1305,15 +1304,15 @@ def _get_user_by_name_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1337,7 +1336,7 @@ def _get_user_by_name_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1366,14 +1365,14 @@ def login_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> str:
"""Logs user into the system
@@ -1415,7 +1414,7 @@ def login_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1438,14 +1437,14 @@ def login_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[str]:
"""Logs user into the system
@@ -1487,7 +1486,7 @@ def login_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1510,14 +1509,14 @@ def login_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs user into the system
@@ -1559,7 +1558,7 @@ def login_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'200': "str",
'400': None,
}
@@ -1582,15 +1581,15 @@ def _login_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1620,7 +1619,7 @@ def _login_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1647,14 +1646,14 @@ def logout_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Logs out current logged in user session
@@ -1690,7 +1689,7 @@ def logout_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1709,14 +1708,14 @@ def logout_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Logs out current logged in user session
@@ -1752,7 +1751,7 @@ def logout_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1771,14 +1770,14 @@ def logout_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Logs out current logged in user session
@@ -1814,7 +1813,7 @@ def logout_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
}
response_data = self.api_client.call_api(
*_param,
@@ -1833,15 +1832,15 @@ def _logout_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -1855,7 +1854,7 @@ def _logout_user_serialize(
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
@@ -1884,14 +1883,14 @@ def update_user(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> None:
"""Updated user
@@ -1933,7 +1932,7 @@ def update_user(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -1956,14 +1955,14 @@ def update_user_with_http_info(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[None]:
"""Updated user
@@ -2005,7 +2004,7 @@ def update_user_with_http_info(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2028,14 +2027,14 @@ def update_user_without_preload_content(
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
- Tuple[
+ tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _request_auth: Optional[dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
- _headers: Optional[Dict[StrictStr, Any]] = None,
+ _headers: Optional[dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Updated user
@@ -2077,7 +2076,7 @@ def update_user_without_preload_content(
_host_index=_host_index
)
- _response_types_map: Dict[str, Optional[str]] = {
+ _response_types_map: dict[str, Optional[str]] = {
'400': None,
'404': None,
}
@@ -2100,15 +2099,15 @@ def _update_user_serialize(
_host = None
- _collection_formats: Dict[str, str] = {
+ _collection_formats: dict[str, str] = {
}
- _path_params: Dict[str, str] = {}
- _query_params: List[Tuple[str, str]] = []
- _header_params: Dict[str, Optional[str]] = _headers or {}
- _form_params: List[Tuple[str, str]] = []
- _files: Dict[
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
+ _path_params: dict[str, str] = {}
+ _query_params: list[tuple[str, str]] = []
+ _header_params: dict[str, Optional[str]] = _headers or {}
+ _form_params: list[tuple[str, str]] = []
+ _files: dict[
+ str, Union[str, bytes, list[str], list[bytes], list[tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None
@@ -2139,7 +2138,7 @@ def _update_user_serialize(
_header_params['Content-Type'] = _default_content_type
# authentication setting
- _auth_settings: List[str] = [
+ _auth_settings: list[str] = [
]
return self.api_client.param_serialize(
diff --git a/samples/openapi3/client/petstore/python/petstore_api/api_client.py b/samples/openapi3/client/petstore/python/petstore_api/api_client.py
index d388566cbbe2..282fc86149b9 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/api_client.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/api_client.py
@@ -23,7 +23,7 @@
import uuid
from urllib.parse import quote
-from typing import Tuple, Optional, List, Dict, Union
+from typing import Optional, Union
from pydantic import SecretStr
from petstore_api.configuration import Configuration
@@ -40,7 +40,7 @@
ServiceException
)
-RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
+RequestSerialized = tuple[str, str, dict[str, str], Optional[str], list[str]]
class ApiClient:
"""Generic API client for OpenAPI client library builds.
@@ -286,7 +286,7 @@ def call_api(
def response_deserialize(
self,
response_data: rest.RESTResponse,
- response_types_map: Optional[Dict[str, ApiResponseT]]=None
+ response_types_map: Optional[dict[str, ApiResponseT]]=None
) -> ApiResponse[ApiResponseT]:
"""Deserializes response into an object.
:param response_data: RESTResponse object to be deserialized.
@@ -434,16 +434,16 @@ def __deserialize(self, data, klass):
return None
if isinstance(klass, str):
- if klass.startswith('List['):
- m = re.match(r'List\[(.*)]', klass)
- assert m is not None, "Malformed List type definition"
+ if klass.startswith('list['):
+ m = re.match(r'list\[(.*)]', klass)
+ assert m is not None, "Malformed list type definition"
sub_kls = m.group(1)
return [self.__deserialize(sub_data, sub_kls)
for sub_data in data]
- if klass.startswith('Dict['):
- m = re.match(r'Dict\[([^,]*), (.*)]', klass)
- assert m is not None, "Malformed Dict type definition"
+ if klass.startswith('dict['):
+ m = re.match(r'dict\[([^,]*), (.*)]', klass)
+ assert m is not None, "Malformed dict type definition"
sub_kls = m.group(2)
return {k: self.__deserialize(v, sub_kls)
for k, v in data.items()}
@@ -478,7 +478,7 @@ def parameters_to_tuples(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: Parameters as list of tuples, collections formatted
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -508,7 +508,7 @@ def parameters_to_url_query(self, params, collection_formats):
:param dict collection_formats: Parameter collection formats
:return: URL query string (e.g. a=Hello%20World&b=123)
"""
- new_params: List[Tuple[str, str]] = []
+ new_params: list[tuple[str, str]] = []
if collection_formats is None:
collection_formats = {}
for k, v in params.items() if isinstance(params, dict) else params:
@@ -542,7 +542,7 @@ def parameters_to_url_query(self, params, collection_formats):
def files_parameters(
self,
- files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]],
+ files: dict[str, Union[str, bytes, list[str], list[bytes], tuple[str, bytes]]],
):
"""Builds form parameters.
@@ -575,7 +575,7 @@ def files_parameters(
)
return params
- def select_header_accept(self, accepts: List[str]) -> Optional[str]:
+ def select_header_accept(self, accepts: list[str]) -> Optional[str]:
"""Returns `Accept` based on an array of accepts provided.
:param accepts: List of headers.
diff --git a/samples/openapi3/client/petstore/python/petstore_api/configuration.py b/samples/openapi3/client/petstore/python/petstore_api/configuration.py
index e50683d07366..19d21c6a8883 100755
--- a/samples/openapi3/client/petstore/python/petstore_api/configuration.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/configuration.py
@@ -16,7 +16,7 @@
from logging import FileHandler
import multiprocessing
import sys
-from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union
+from typing import Any, ClassVar, Literal, Optional, TypedDict, Union
from typing_extensions import NotRequired, Self
import urllib3
@@ -29,7 +29,7 @@
'minLength', 'pattern', 'maxItems', 'minItems'
}
-ServerVariablesT = Dict[str, str]
+ServerVariablesT = dict[str, str]
GenericAuthSetting = TypedDict(
"GenericAuthSetting",
@@ -126,13 +126,13 @@
class HostSettingVariable(TypedDict):
description: str
default_value: str
- enum_values: List[str]
+ enum_values: list[str]
class HostSetting(TypedDict):
url: str
description: str
- variables: NotRequired[Dict[str, HostSettingVariable]]
+ variables: NotRequired[dict[str, HostSettingVariable]]
class Configuration:
@@ -266,16 +266,16 @@ class Configuration:
def __init__(
self,
host: Optional[str]=None,
- api_key: Optional[Dict[str, str]]=None,
- api_key_prefix: Optional[Dict[str, str]]=None,
+ api_key: Optional[dict[str, str]]=None,
+ api_key_prefix: Optional[dict[str, str]]=None,
username: Optional[str]=None,
password: Optional[str]=None,
access_token: Optional[str]=None,
signing_info: Optional[HttpSigningConfiguration]=None,
server_index: Optional[int]=None,
server_variables: Optional[ServerVariablesT]=None,
- server_operation_index: Optional[Dict[int, int]]=None,
- server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None,
+ server_operation_index: Optional[dict[int, int]]=None,
+ server_operation_variables: Optional[dict[int, ServerVariablesT]]=None,
ignore_operation_servers: bool=False,
ssl_ca_cert: Optional[str]=None,
retries: Optional[Union[int, urllib3.util.retry.Retry]] = None,
@@ -425,7 +425,7 @@ def __init__(
"""date format
"""
- def __deepcopy__(self, memo: Dict[int, Any]) -> Self:
+ def __deepcopy__(self, memo: dict[int, Any]) -> Self:
cls = self.__class__
result = cls.__new__(cls)
memo[id(self)] = result
@@ -668,7 +668,7 @@ def to_debug_report(self) -> str:
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)
- def get_host_settings(self) -> List[HostSetting]:
+ def get_host_settings(self) -> list[HostSetting]:
"""Gets an array of host settings
:return: An array of host settings
@@ -721,7 +721,7 @@ def get_host_from_settings(
self,
index: Optional[int],
variables: Optional[ServerVariablesT]=None,
- servers: Optional[List[HostSetting]]=None,
+ servers: Optional[list[HostSetting]]=None,
) -> str:
"""Gets host URL based on the index and variables
:param index: array index of the host settings
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_any_type.py b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_any_type.py
index 19db20137bc4..8664dd11b01d 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_any_type.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_any_type.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesAnyType(BaseModel):
AdditionalPropertiesAnyType
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesAnyType from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_class.py
index 2f03e1fa1758..b92c83ddda06 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.pet import Pet
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,11 +28,11 @@ class AdditionalPropertiesClass(BaseModel):
"""
AdditionalPropertiesClass
""" # noqa: E501
- map_property: Optional[Dict[str, StrictStr]] = None
- map_of_map_property: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_map_non_primitive_property: Optional[Dict[str, Dict[str, Pet]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
+ map_property: Optional[dict[str, StrictStr]] = None
+ map_of_map_property: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_map_non_primitive_property: Optional[dict[str, dict[str, Pet]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["map_property", "map_of_map_property", "map_of_map_non_primitive_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_object.py b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_object.py
index d23fd87e51f3..2f1556c5e9ec 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_object.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesObject(BaseModel):
AdditionalPropertiesObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_with_description_only.py b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_with_description_only.py
index b1f42400b676..f12bbeaec7f8 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_with_description_only.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/additional_properties_with_description_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AdditionalPropertiesWithDescriptionOnly(BaseModel):
AdditionalPropertiesWithDescriptionOnly
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AdditionalPropertiesWithDescriptionOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/all_of_super_model.py
index 86a856c01520..50ed4f60e43a 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/all_of_super_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/all_of_super_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class AllOfSuperModel(BaseModel):
AllOfSuperModel
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfSuperModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python/petstore_api/models/all_of_with_single_ref.py
index 371730978cfa..dada4257ce40 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/all_of_with_single_ref.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/all_of_with_single_ref.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.single_ref_type import SingleRefType
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class AllOfWithSingleRef(BaseModel):
""" # noqa: E501
username: Optional[StrictStr] = None
single_ref_type: Optional[SingleRefType] = Field(default=None, alias="SingleRefType")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["username", "SingleRefType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["username", "SingleRefType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of AllOfWithSingleRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/animal.py b/samples/openapi3/client/petstore/python/petstore_api/models/animal.py
index 562423002c0a..e370fb2e82d8 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/animal.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/animal.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class Animal(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: Optional[StrictStr] = 'red'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -50,12 +50,12 @@ class Animal(BaseModel):
__discriminator_property_name: ClassVar[str] = 'className'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Cat': 'Cat','Dog': 'Dog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -76,7 +76,7 @@ def from_json(cls, json_str: str) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -104,7 +104,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[Cat, Dog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[Cat, Dog]]:
"""Create an instance of Animal from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/any_of_color.py b/samples/openapi3/client/petstore/python/petstore_api/models/any_of_color.py
index f6d277e79498..2039c0de8af9 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/any_of_color.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/any_of_color.py
@@ -18,30 +18,30 @@
import pprint
import re # noqa: F401
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import List, Optional
+from typing import Optional
from typing_extensions import Annotated
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
-ANYOFCOLOR_ANY_OF_SCHEMAS = ["List[int]", "str"]
+ANYOFCOLOR_ANY_OF_SCHEMAS = ["list[int]", "str"]
class AnyOfColor(BaseModel):
"""
Any of RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- anyof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- anyof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ anyof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
anyof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
if TYPE_CHECKING:
- actual_instance: Optional[Union[List[int], str]] = None
+ actual_instance: Optional[Union[list[int], str]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "List[int]", "str" }
+ any_of_schemas: set[str] = { "list[int]", "str" }
model_config = {
"validate_assignment": True,
@@ -62,13 +62,13 @@ def __init__(self, *args, **kwargs) -> None:
def actual_instance_must_validate_anyof(cls, v):
instance = AnyOfColor.model_construct()
error_messages = []
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_1_validator = v
return v
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.anyof_schema_2_validator = v
return v
@@ -82,12 +82,12 @@ def actual_instance_must_validate_anyof(cls, v):
error_messages.append(str(e))
if error_messages:
# no match
- raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting the actual_instance in AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -95,7 +95,7 @@ def from_json(cls, json_str: str) -> Self:
"""Returns the object represented by the json string"""
instance = cls.model_construct()
error_messages = []
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_1_validator = json.loads(json_str)
@@ -104,7 +104,7 @@ def from_json(cls, json_str: str) -> Self:
return instance
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.anyof_schema_2_validator = json.loads(json_str)
@@ -125,7 +125,7 @@ def from_json(cls, json_str: str) -> Self:
if error_messages:
# no match
- raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into AnyOfColor with anyOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -139,7 +139,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/any_of_pig.py b/samples/openapi3/client/petstore/python/petstore_api/models/any_of_pig.py
index c949e136f415..0211d0291d94 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/any_of_pig.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/any_of_pig.py
@@ -21,7 +21,7 @@
from typing import Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
-from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict
+from typing import Union, Any, TYPE_CHECKING, Optional
from typing_extensions import Literal, Self
from pydantic import Field
@@ -40,7 +40,7 @@ class AnyOfPig(BaseModel):
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
else:
actual_instance: Any = None
- any_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ any_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = {
"validate_assignment": True,
@@ -80,7 +80,7 @@ def actual_instance_must_validate_anyof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Self:
+ def from_dict(cls, obj: dict[str, Any]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -117,7 +117,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_model.py
index f290c6a19437..b0b1081e2e0b 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ArrayOfArrayOfModel(BaseModel):
"""
ArrayOfArrayOfModel
""" # noqa: E501
- another_property: Optional[List[List[Tag]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["another_property"]
+ another_property: Optional[list[list[Tag]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["another_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_number_only.py
index bf87ebab7ef8..91d1b814abe3 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class ArrayOfArrayOfNumberOnly(BaseModel):
"""
ArrayOfArrayOfNumberOnly
""" # noqa: E501
- array_array_number: Optional[List[List[StrictFloat]]] = Field(default=None, alias="ArrayArrayNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["ArrayArrayNumber"]
+ array_array_number: Optional[list[list[StrictFloat]]] = Field(default=None, alias="ArrayArrayNumber")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["ArrayArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_map_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_map_model.py
index 5f2639374f32..087fd031ad5f 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_map_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_map_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ArrayOfMapModel(BaseModel):
"""
ArrayOfMapModel
""" # noqa: E501
- array_of_map_property: Optional[List[Dict[str, Tag]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["array_of_map_property"]
+ array_of_map_property: Optional[list[dict[str, Tag]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["array_of_map_property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfMapModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_number_only.py
index c6c50aed2d41..fa82d1aa49d0 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/array_of_number_only.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/array_of_number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class ArrayOfNumberOnly(BaseModel):
"""
ArrayOfNumberOnly
""" # noqa: E501
- array_number: Optional[List[StrictFloat]] = Field(default=None, alias="ArrayNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["ArrayNumber"]
+ array_number: Optional[list[StrictFloat]] = Field(default=None, alias="ArrayNumber")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["ArrayNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayOfNumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python/petstore_api/models/array_test.py
index bbe20c814a4d..7406b87ce878 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/array_test.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/array_test.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.read_only_first import ReadOnlyFirst
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,12 +29,12 @@ class ArrayTest(BaseModel):
"""
ArrayTest
""" # noqa: E501
- array_of_string: Optional[Annotated[List[StrictStr], Field(min_length=0, max_length=3)]] = None
- array_of_nullable_float: Optional[List[Optional[StrictFloat]]] = None
- array_array_of_integer: Optional[List[List[StrictInt]]] = None
- array_array_of_model: Optional[List[List[ReadOnlyFirst]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
+ array_of_string: Optional[Annotated[list[StrictStr], Field(min_length=0, max_length=3)]] = None
+ array_of_nullable_float: Optional[list[Optional[StrictFloat]]] = None
+ array_array_of_integer: Optional[list[list[StrictInt]]] = None
+ array_array_of_model: Optional[list[list[ReadOnlyFirst]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["array_of_string", "array_of_nullable_float", "array_array_of_integer", "array_array_of_model"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ArrayTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ArrayTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/base_discriminator.py b/samples/openapi3/client/petstore/python/petstore_api/models/base_discriminator.py
index c1111f98976d..1124f17136e8 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/base_discriminator.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/base_discriminator.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class BaseDiscriminator(BaseModel):
BaseDiscriminator
""" # noqa: E501
type_name: Optional[StrictStr] = Field(default=None, alias="_typeName")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName"]
model_config = ConfigDict(
validate_by_name=True,
@@ -49,12 +49,12 @@ class BaseDiscriminator(BaseModel):
__discriminator_property_name: ClassVar[str] = '_typeName'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'string': 'PrimitiveString','Info': 'Info'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -75,7 +75,7 @@ def from_json(cls, json_str: str) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -103,7 +103,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[PrimitiveString, Info]]:
"""Create an instance of BaseDiscriminator from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python/petstore_api/models/basque_pig.py
index d61619ca2efb..8296939aa774 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/basque_pig.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/basque_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class BasquePig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
color: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of BasquePig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of BasquePig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python/petstore_api/models/bathing.py
index c4d595a498b8..80f970898953 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/bathing.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/bathing.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class Bathing(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Bathing from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Bathing from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python/petstore_api/models/capitalization.py
index 1f38a7124a7f..6d2e10dfa13b 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/capitalization.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/capitalization.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,8 +33,8 @@ class Capitalization(BaseModel):
capital_snake: Optional[StrictStr] = Field(default=None, alias="Capital_Snake")
sca_eth_flow_points: Optional[StrictStr] = Field(default=None, alias="SCA_ETH_Flow_Points")
att_name: Optional[StrictStr] = Field(default=None, description="Name of the pet ", alias="ATT_NAME")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["smallCamel", "CapitalCamel", "small_Snake", "Capital_Snake", "SCA_ETH_Flow_Points", "ATT_NAME"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Capitalization from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Capitalization from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python/petstore_api/models/cat.py
index dfdf659272c0..c113268eaa9c 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/cat.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/cat.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Cat(Animal):
Cat
""" # noqa: E501
declawed: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color", "declawed"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color", "declawed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Cat from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Cat from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/category.py b/samples/openapi3/client/petstore/python/petstore_api/models/category.py
index 425e409c7adc..55c20e9c42cd 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/category.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/category.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python/petstore_api/models/circular_all_of_ref.py
index f03de1a2c7fb..9874002470b5 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class CircularAllOfRef(BaseModel):
CircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- second_circular_all_of_ref: Optional[List[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name", "secondCircularAllOfRef"]
+ second_circular_all_of_ref: Optional[list[SecondCircularAllOfRef]] = Field(default=None, alias="secondCircularAllOfRef")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name", "secondCircularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/circular_reference_model.py
index 4a46e13580af..7bf706aa6e99 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/circular_reference_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/circular_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class CircularReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[FirstRef] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CircularReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/class_model.py
index 752706128969..37e996bbe35b 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/class_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/class_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ClassModel(BaseModel):
Model for testing model with \"_class\" property
""" # noqa: E501
var_class: Optional[StrictStr] = Field(default=None, alias="_class")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_class"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ClassModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ClassModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/client.py b/samples/openapi3/client/petstore/python/petstore_api/models/client.py
index cbbea6d33af4..359f4f703b6f 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/client.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/client.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Client(BaseModel):
Client
""" # noqa: E501
client: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["client"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["client"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Client from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Client from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/color.py b/samples/openapi3/client/petstore/python/petstore_api/models/color.py
index bb740fb597d4..b3c3404d00f7 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/color.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/color.py
@@ -16,26 +16,26 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
-COLOR_ONE_OF_SCHEMAS = ["List[int]", "str"]
+COLOR_ONE_OF_SCHEMAS = ["list[int]", "str"]
class Color(BaseModel):
"""
RGB array, RGBA array, or hex string.
"""
- # data type: List[int]
- oneof_schema_1_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
- # data type: List[int]
- oneof_schema_2_validator: Optional[Annotated[List[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_1_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=3, max_length=3)]] = Field(default=None, description="RGB three element array with values 0-255.")
+ # data type: list[int]
+ oneof_schema_2_validator: Optional[Annotated[list[Annotated[int, Field(le=255, strict=True, ge=0)]], Field(min_length=4, max_length=4)]] = Field(default=None, description="RGBA four element array with values 0-255.")
# data type: str
oneof_schema_3_validator: Optional[Annotated[str, Field(min_length=7, strict=True, max_length=7)]] = Field(default=None, description="Hex color string, such as #00FF00.")
- actual_instance: Optional[Union[List[int], str]] = None
- one_of_schemas: Set[str] = { "List[int]", "str" }
+ actual_instance: Optional[Union[list[int], str]] = None
+ one_of_schemas: set[str] = { "list[int]", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -61,13 +61,13 @@ def actual_instance_must_validate_oneof(cls, v):
instance = Color.model_construct()
error_messages = []
match = 0
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_1_validator = v
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # validate data type: List[int]
+ # validate data type: list[int]
try:
instance.oneof_schema_2_validator = v
match += 1
@@ -81,15 +81,15 @@ def actual_instance_must_validate_oneof(cls, v):
error_messages.append(str(e))
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when setting `actual_instance` in Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -102,7 +102,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
error_messages = []
match = 0
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_1_validator = json.loads(json_str)
@@ -111,7 +111,7 @@ def from_json(cls, json_str: Optional[str]) -> Self:
match += 1
except (ValidationError, ValueError) as e:
error_messages.append(str(e))
- # deserialize data into List[int]
+ # deserialize data into list[int]
try:
# validation
instance.oneof_schema_2_validator = json.loads(json_str)
@@ -132,10 +132,10 @@ def from_json(cls, json_str: Optional[str]) -> Self:
if match > 1:
# more than 1 match
- raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("Multiple matches found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
elif match == 0:
# no match
- raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: List[int], str. Details: " + ", ".join(error_messages))
+ raise ValueError("No match found when deserializing the JSON string into Color with oneOf schemas: list[int], str. Details: " + ", ".join(error_messages))
else:
return instance
@@ -149,7 +149,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], List[int], str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], list[int], str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/creature.py b/samples/openapi3/client/petstore/python/petstore_api/models/creature.py
index e8bcab1ec3f1..c55567257e88 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/creature.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/creature.py
@@ -19,9 +19,9 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
+from typing import Any, ClassVar, Union
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class Creature(BaseModel):
""" # noqa: E501
info: CreatureInfo
type: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["info", "type"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["info", "type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -50,12 +50,12 @@ class Creature(BaseModel):
__discriminator_property_name: ClassVar[str] = 'type'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'Hunting__Dog': 'HuntingDog'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -76,7 +76,7 @@ def from_json(cls, json_str: str) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -107,7 +107,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[HuntingDog]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[HuntingDog]]:
"""Create an instance of Creature from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python/petstore_api/models/creature_info.py
index ba91bd0874f3..6f8678f84344 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/creature_info.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/creature_info.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class CreatureInfo(BaseModel):
CreatureInfo
""" # noqa: E501
name: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of CreatureInfo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of CreatureInfo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python/petstore_api/models/danish_pig.py
index 0f9f43773ae7..7bb81b6446f1 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/danish_pig.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/danish_pig.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class DanishPig(BaseModel):
""" # noqa: E501
class_name: StrictStr = Field(alias="className")
size: StrictInt
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "size"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "size"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DanishPig from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DanishPig from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python/petstore_api/models/deprecated_object.py
index f310e64b7a83..bdb5acb5887d 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/deprecated_object.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/deprecated_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class DeprecatedObject(BaseModel):
DeprecatedObject
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DeprecatedObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_sub.py
index 2250170a4633..c31b01a139eb 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_sub.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_sub.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from petstore_api.models.discriminator_all_of_super import DiscriminatorAllOfSuper
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class DiscriminatorAllOfSub(DiscriminatorAllOfSuper):
"""
DiscriminatorAllOfSub
""" # noqa: E501
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["elementType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DiscriminatorAllOfSub from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_super.py b/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_super.py
index 5dcc0b569e8f..0ac2c6ece21f 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_super.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/discriminator_all_of_super.py
@@ -19,8 +19,8 @@
from importlib import import_module
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Union
-from typing import Optional, Set
+from typing import Any, ClassVar, Union
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,8 +33,8 @@ class DiscriminatorAllOfSuper(BaseModel):
DiscriminatorAllOfSuper
""" # noqa: E501
element_type: StrictStr = Field(alias="elementType")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["elementType"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["elementType"]
model_config = ConfigDict(
validate_by_name=True,
@@ -48,12 +48,12 @@ class DiscriminatorAllOfSuper(BaseModel):
__discriminator_property_name: ClassVar[str] = 'elementType'
# discriminator mappings
- __discriminator_value_class_map: ClassVar[Dict[str, str]] = {
+ __discriminator_value_class_map: ClassVar[dict[str, str]] = {
'DiscriminatorAllOfSub': 'DiscriminatorAllOfSub'
}
@classmethod
- def get_discriminator_value(cls, obj: Dict[str, Any]) -> Optional[str]:
+ def get_discriminator_value(cls, obj: dict[str, Any]) -> Optional[str]:
"""Returns the discriminator value (object type) of the data"""
discriminator_value = obj[cls.__discriminator_property_name]
if discriminator_value:
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -102,7 +102,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
+ def from_dict(cls, obj: dict[str, Any]) -> Optional[Union[DiscriminatorAllOfSub]]:
"""Create an instance of DiscriminatorAllOfSuper from a dict"""
# look up the object type based on discriminator mapping
object_type = cls.get_discriminator_value(obj)
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python/petstore_api/models/dog.py
index a5c869b8de82..97a827ccb393 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/dog.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/dog.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Dog(Animal):
Dog
""" # noqa: E501
breed: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["className", "color", "breed"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["className", "color", "breed"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Dog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Dog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/dummy_model.py
index 9fdf057cdb63..55e8bc485bb1 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/dummy_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/dummy_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class DummyModel(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SelfReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of DummyModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of DummyModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python/petstore_api/models/enum_arrays.py
index 270f540ef1b6..2d8b80c022dd 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/enum_arrays.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/enum_arrays.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class EnumArrays(BaseModel):
EnumArrays
""" # noqa: E501
just_symbol: Optional[StrictStr] = None
- array_enum: Optional[List[StrictStr]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["just_symbol", "array_enum"]
+ array_enum: Optional[list[StrictStr]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["just_symbol", "array_enum"]
@field_validator('just_symbol')
def just_symbol_validate_enum(cls, value):
@@ -74,7 +74,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -102,7 +102,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/enum_ref_with_default_value.py b/samples/openapi3/client/petstore/python/petstore_api/models/enum_ref_with_default_value.py
index d35a7f9d426a..d1051ddaa7a4 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/enum_ref_with_default_value.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/enum_ref_with_default_value.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.data_output_format import DataOutputFormat
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class EnumRefWithDefaultValue(BaseModel):
EnumRefWithDefaultValue
""" # noqa: E501
report_format: Optional[DataOutputFormat] = DataOutputFormat.JSON
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["report_format"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["report_format"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumRefWithDefaultValue from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python/petstore_api/models/enum_test.py
index b38efd78ef7e..47285705cfec 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/enum_test.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/enum_test.py
@@ -18,14 +18,14 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.enum_number_vendor_ext import EnumNumberVendorExt
from petstore_api.models.enum_string_vendor_ext import EnumStringVendorExt
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_default_value import OuterEnumDefaultValue
from petstore_api.models.outer_enum_integer import OuterEnumInteger
from petstore_api.models.outer_enum_integer_default_value import OuterEnumIntegerDefaultValue
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -46,8 +46,8 @@ class EnumTest(BaseModel):
outer_enum_integer_default_value: Optional[OuterEnumIntegerDefaultValue] = Field(default=OuterEnumIntegerDefaultValue.NUMBER_0, alias="outerEnumIntegerDefaultValue")
enum_number_vendor_ext: Optional[EnumNumberVendorExt] = Field(default=None, alias="enumNumberVendorExt")
enum_string_vendor_ext: Optional[EnumStringVendorExt] = Field(default=None, alias="enumStringVendorExt")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["enum_string", "enum_string_required", "enum_integer_default", "enum_integer", "enum_number", "enum_string_single_member", "enum_integer_single_member", "outerEnum", "outerEnumInteger", "outerEnumDefaultValue", "outerEnumIntegerDefaultValue", "enumNumberVendorExt", "enumStringVendorExt"]
@field_validator('enum_string')
def enum_string_validate_enum(cls, value):
@@ -137,7 +137,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of EnumTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -170,7 +170,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of EnumTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python/petstore_api/models/feeding.py
index 3efa9e0ede0e..ed5753ed6bf2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/feeding.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/feeding.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class Feeding(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Feeding from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Feeding from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/file.py b/samples/openapi3/client/petstore/python/petstore_api/models/file.py
index b7670595acb2..bd9639b2a012 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/file.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/file.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class File(BaseModel):
Must be named `File` for test.
""" # noqa: E501
source_uri: Optional[StrictStr] = Field(default=None, description="Test capitalization", alias="sourceURI")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["sourceURI"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["sourceURI"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of File from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of File from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python/petstore_api/models/file_schema_test_class.py
index 80da509938d5..fffa59bcf3cc 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/file_schema_test_class.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/file_schema_test_class.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,9 +29,9 @@ class FileSchemaTestClass(BaseModel):
FileSchemaTestClass
""" # noqa: E501
file: Optional[File] = None
- files: Optional[List[File]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["file", "files"]
+ files: Optional[list[File]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["file", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FileSchemaTestClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python/petstore_api/models/first_ref.py
index 50d561621b36..ba2b14e91374 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/first_ref.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/first_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FirstRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
self_ref: Optional[SecondRef] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "self_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "self_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FirstRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FirstRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python/petstore_api/models/foo.py
index 2d15a0729446..bf3caa8fa2b2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/foo.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/foo.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Foo(BaseModel):
Foo
""" # noqa: E501
bar: Optional[StrictStr] = 'bar'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Foo from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Foo from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python/petstore_api/models/foo_get_default_response.py
index b8ab0cd0dfd1..df25097e4273 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/foo_get_default_response.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/foo_get_default_response.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.foo import Foo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class FooGetDefaultResponse(BaseModel):
FooGetDefaultResponse
""" # noqa: E501
string: Optional[Foo] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["string"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FooGetDefaultResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python/petstore_api/models/format_test.py
index f3f6888b0c7f..eda07f185560 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/format_test.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/format_test.py
@@ -20,10 +20,10 @@
from datetime import date, datetime
from decimal import Decimal
from pydantic import BaseModel, ConfigDict, Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional, Tuple, Union
+from typing import Any, ClassVar, Optional, Union
from typing_extensions import Annotated
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -41,15 +41,15 @@ class FormatTest(BaseModel):
string: Optional[Annotated[str, Field(strict=True)]] = None
string_with_double_quote_pattern: Optional[Annotated[str, Field(strict=True)]] = None
byte: Optional[Union[StrictBytes, StrictStr]] = None
- binary: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None
+ binary: Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]] = None
var_date: date = Field(alias="date")
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
uuid: Optional[UUID] = None
password: Annotated[str, Field(min_length=10, strict=True, max_length=64)]
pattern_with_digits: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string that is a 10 digit number. Can have leading zeros.")
pattern_with_digits_and_delimiter: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["integer", "int32", "int64", "number", "float", "double", "decimal", "string", "string_with_double_quote_pattern", "byte", "binary", "date", "dateTime", "uuid", "password", "pattern_with_digits", "pattern_with_digits_and_delimiter"]
@field_validator('string')
def string_validate_regular_expression(cls, value):
@@ -124,7 +124,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of FormatTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -135,7 +135,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -152,7 +152,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of FormatTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python/petstore_api/models/has_only_read_only.py
index 259ee97dcbab..e19acc704229 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/has_only_read_only.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/has_only_read_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class HasOnlyReadOnly(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
foo: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar", "foo"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar", "foo"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"foo",
"additional_properties",
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HasOnlyReadOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python/petstore_api/models/health_check_result.py
index e333321a7617..dbb9b9750d87 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/health_check_result.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/health_check_result.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class HealthCheckResult(BaseModel):
Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model.
""" # noqa: E501
nullable_message: Optional[StrictStr] = Field(default=None, alias="NullableMessage")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["NullableMessage"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["NullableMessage"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HealthCheckResult from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python/petstore_api/models/hunting_dog.py
index 15c26d355520..6f9238baff32 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/hunting_dog.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/hunting_dog.py
@@ -18,10 +18,10 @@
import json
from pydantic import ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature import Creature
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class HuntingDog(Creature):
HuntingDog
""" # noqa: E501
is_trained: Optional[StrictBool] = Field(default=None, alias="isTrained")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["info", "type", "isTrained"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["info", "type", "isTrained"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of HuntingDog from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of HuntingDog from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/info.py b/samples/openapi3/client/petstore/python/petstore_api/models/info.py
index 71862c10b392..b1c2e37a7b6d 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/info.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/info.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Info(BaseDiscriminator):
Info
""" # noqa: E501
val: Optional[BaseDiscriminator] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName", "val"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName", "val"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Info from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Info from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python/petstore_api/models/inner_dict_with_property.py
index 093d1be68617..d5206c1ea9f6 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/inner_dict_with_property.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/inner_dict_with_property.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class InnerDictWithProperty(BaseModel):
"""
InnerDictWithProperty
""" # noqa: E501
- a_property: Optional[Dict[str, Any]] = Field(default=None, alias="aProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["aProperty"]
+ a_property: Optional[dict[str, Any]] = Field(default=None, alias="aProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["aProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InnerDictWithProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python/petstore_api/models/input_all_of.py
index 4d1ff0e87aac..e85aca75ae20 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/input_all_of.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/input_all_of.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class InputAllOf(BaseModel):
"""
InputAllOf
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of InputAllOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of InputAllOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/int_or_string.py b/samples/openapi3/client/petstore/python/petstore_api/models/int_or_string.py
index f2a5a0a2d4a3..02180a2d6a53 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/int_or_string.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/int_or_string.py
@@ -16,10 +16,10 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from typing_extensions import Annotated
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
INTORSTRING_ONE_OF_SCHEMAS = ["int", "str"]
@@ -33,7 +33,7 @@ class IntOrString(BaseModel):
# data type: str
oneof_schema_2_validator: Optional[StrictStr] = None
actual_instance: Optional[Union[int, str]] = None
- one_of_schemas: Set[str] = { "int", "str" }
+ one_of_schemas: set[str] = { "int", "str" }
model_config = ConfigDict(
validate_assignment=True,
@@ -78,7 +78,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -126,7 +126,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], int, str]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], int, str]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python/petstore_api/models/list_class.py
index 3c64d3024686..415b50cf9f56 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/list_class.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/list_class.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ListClass(BaseModel):
ListClass
""" # noqa: E501
var_123_list: Optional[StrictStr] = Field(default=None, alias="123-list")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["123-list"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["123-list"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ListClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ListClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/map_of_array_of_model.py
index c6018ae272c6..b6c2f85aaa17 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/map_of_array_of_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/map_of_array_of_model.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class MapOfArrayOfModel(BaseModel):
"""
MapOfArrayOfModel
""" # noqa: E501
- shop_id_to_org_online_lip_map: Optional[Dict[str, List[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["shopIdToOrgOnlineLipMap"]
+ shop_id_to_org_online_lip_map: Optional[dict[str, list[Tag]]] = Field(default=None, alias="shopIdToOrgOnlineLipMap")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["shopIdToOrgOnlineLipMap"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapOfArrayOfModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python/petstore_api/models/map_test.py
index 77569b9bf3b4..544680a197be 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/map_test.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/map_test.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,12 +27,12 @@ class MapTest(BaseModel):
"""
MapTest
""" # noqa: E501
- map_map_of_string: Optional[Dict[str, Dict[str, StrictStr]]] = None
- map_of_enum_string: Optional[Dict[str, StrictStr]] = None
- direct_map: Optional[Dict[str, StrictBool]] = None
- indirect_map: Optional[Dict[str, StrictBool]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
+ map_map_of_string: Optional[dict[str, dict[str, StrictStr]]] = None
+ map_of_enum_string: Optional[dict[str, StrictStr]] = None
+ direct_map: Optional[dict[str, StrictBool]] = None
+ indirect_map: Optional[dict[str, StrictBool]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["map_map_of_string", "map_of_enum_string", "direct_map", "indirect_map"]
@field_validator('map_of_enum_string')
def map_of_enum_string_validate_enum(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MapTest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MapTest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python/petstore_api/models/mixed_properties_and_additional_properties_class.py
index 65da9a205120..c61d4557e8f2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/mixed_properties_and_additional_properties_class.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/mixed_properties_and_additional_properties_class.py
@@ -19,10 +19,10 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
from petstore_api.models.animal import Animal
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,9 +32,9 @@ class MixedPropertiesAndAdditionalPropertiesClass(BaseModel):
""" # noqa: E501
uuid: Optional[UUID] = None
date_time: Optional[datetime] = Field(default=None, alias="dateTime")
- map: Optional[Dict[str, Animal]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["uuid", "dateTime", "map"]
+ map: Optional[dict[str, Animal]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["uuid", "dateTime", "map"]
model_config = ConfigDict(
validate_by_name=True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -92,7 +92,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MixedPropertiesAndAdditionalPropertiesClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python/petstore_api/models/model200_response.py
index a8f10880da53..5e764264f9b2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/model200_response.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/model200_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Model200Response(BaseModel):
""" # noqa: E501
name: Optional[StrictInt] = None
var_class: Optional[StrictStr] = Field(default=None, alias="class")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name", "class"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name", "class"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Model200Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Model200Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python/petstore_api/models/model_api_response.py
index 45960f5877ff..8b1bc67d6ebe 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/model_api_response.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/model_api_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class ModelApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["code", "type", "message"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["code", "type", "message"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelApiResponse from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python/petstore_api/models/model_field.py
index bf6560e93e13..80e7cfd91d3a 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/model_field.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/model_field.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ModelField(BaseModel):
ModelField
""" # noqa: E501
var_field: Optional[StrictStr] = Field(default=None, alias="field")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["field"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["field"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelField from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelField from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python/petstore_api/models/model_return.py
index d564c896d7db..30c65c5d53ee 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/model_return.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/model_return.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ModelReturn(BaseModel):
Model for testing reserved words
""" # noqa: E501
var_return: Optional[StrictInt] = Field(default=None, alias="return")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["return"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["return"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ModelReturn from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ModelReturn from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python/petstore_api/models/multi_arrays.py
index e1764bac50af..d5c8e29094d2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/multi_arrays.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/multi_arrays.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.file import File
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,10 +29,10 @@ class MultiArrays(BaseModel):
"""
MultiArrays
""" # noqa: E501
- tags: Optional[List[Tag]] = None
- files: Optional[List[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["tags", "files"]
+ tags: Optional[list[Tag]] = None
+ files: Optional[list[File]] = Field(default=None, description="Another array of objects in addition to tags (mypy check to not to reuse the same iterator)")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["tags", "files"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of MultiArrays from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -97,7 +97,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of MultiArrays from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/name.py b/samples/openapi3/client/petstore/python/petstore_api/models/name.py
index a5c21f36b2b9..79d221125478 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/name.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class Name(BaseModel):
snake_case: Optional[StrictInt] = None
var_property: Optional[StrictStr] = Field(default=None, alias="property")
var_123_number: Optional[StrictInt] = Field(default=None, alias="123Number")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name", "snake_case", "property", "123Number"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name", "snake_case", "property", "123Number"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Name from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -68,7 +68,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"snake_case",
"var_123_number",
"additional_properties",
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Name from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/nullable_class.py b/samples/openapi3/client/petstore/python/petstore_api/models/nullable_class.py
index 2504f4c359f5..84d2b7734790 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/nullable_class.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/nullable_class.py
@@ -19,8 +19,8 @@
from datetime import date, datetime
from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,14 +35,14 @@ class NullableClass(BaseModel):
string_prop: Optional[StrictStr] = None
date_prop: Optional[date] = None
datetime_prop: Optional[datetime] = None
- array_nullable_prop: Optional[List[Dict[str, Any]]] = None
- array_and_items_nullable_prop: Optional[List[Optional[Dict[str, Any]]]] = None
- array_items_nullable: Optional[List[Optional[Dict[str, Any]]]] = None
- object_nullable_prop: Optional[Dict[str, Dict[str, Any]]] = None
- object_and_items_nullable_prop: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- object_items_nullable: Optional[Dict[str, Optional[Dict[str, Any]]]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
+ array_nullable_prop: Optional[list[dict[str, Any]]] = None
+ array_and_items_nullable_prop: Optional[list[Optional[dict[str, Any]]]] = None
+ array_items_nullable: Optional[list[Optional[dict[str, Any]]]] = None
+ object_nullable_prop: Optional[dict[str, dict[str, Any]]] = None
+ object_and_items_nullable_prop: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ object_items_nullable: Optional[dict[str, Optional[dict[str, Any]]]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["required_integer_prop", "integer_prop", "number_prop", "boolean_prop", "string_prop", "date_prop", "datetime_prop", "array_nullable_prop", "array_and_items_nullable_prop", "array_items_nullable", "object_nullable_prop", "object_and_items_nullable_prop", "object_items_nullable"]
model_config = ConfigDict(
validate_by_name=True,
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableClass from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -148,7 +148,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableClass from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python/petstore_api/models/nullable_property.py
index 0d838a27738e..5216a6246ef7 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/nullable_property.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/nullable_property.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class NullableProperty(BaseModel):
""" # noqa: E501
id: StrictInt
name: Optional[Annotated[str, Field(strict=True)]]
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
@field_validator('name')
def name_validate_regular_expression(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NullableProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -78,7 +78,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -100,7 +100,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NullableProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python/petstore_api/models/number_only.py
index e9c7ef6ddb2f..b411727d51ad 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/number_only.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/number_only.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class NumberOnly(BaseModel):
NumberOnly
""" # noqa: E501
just_number: Optional[StrictFloat] = Field(default=None, alias="JustNumber")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["JustNumber"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["JustNumber"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of NumberOnly from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of NumberOnly from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python/petstore_api/models/object_to_test_additional_properties.py
index 0d8dd42a4b64..9990828cee5f 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/object_to_test_additional_properties.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/object_to_test_additional_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictBool
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class ObjectToTestAdditionalProperties(BaseModel):
Minimal object
""" # noqa: E501
var_property: Optional[StrictBool] = Field(default=False, description="Property", alias="property")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["property"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["property"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectToTestAdditionalProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python/petstore_api/models/object_with_deprecated_fields.py
index 9b9ff8540e75..b5955ffa6403 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/object_with_deprecated_fields.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/object_with_deprecated_fields.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.deprecated_object import DeprecatedObject
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,9 +31,9 @@ class ObjectWithDeprecatedFields(BaseModel):
uuid: Optional[StrictStr] = None
id: Optional[StrictFloat] = None
deprecated_ref: Optional[DeprecatedObject] = Field(default=None, alias="deprecatedRef")
- bars: Optional[List[StrictStr]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["uuid", "id", "deprecatedRef", "bars"]
+ bars: Optional[list[StrictStr]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["uuid", "id", "deprecatedRef", "bars"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -67,7 +67,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ObjectWithDeprecatedFields from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/one_of_enum_string.py b/samples/openapi3/client/petstore/python/petstore_api/models/one_of_enum_string.py
index f180178737db..4d35cc225469 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/one_of_enum_string.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/one_of_enum_string.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.enum_string1 import EnumString1
from petstore_api.models.enum_string2 import EnumString2
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
ONEOFENUMSTRING_ONE_OF_SCHEMAS = ["EnumString1", "EnumString2"]
@@ -34,7 +34,7 @@ class OneOfEnumString(BaseModel):
# data type: EnumString2
oneof_schema_2_validator: Optional[EnumString2] = None
actual_instance: Optional[Union[EnumString1, EnumString2]] = None
- one_of_schemas: Set[str] = { "EnumString1", "EnumString2" }
+ one_of_schemas: set[str] = { "EnumString1", "EnumString2" }
model_config = ConfigDict(
validate_assignment=True,
@@ -77,7 +77,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -119,7 +119,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], EnumString1, EnumString2]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], EnumString1, EnumString2]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/order.py b/samples/openapi3/client/petstore/python/petstore_api/models/order.py
index c7c9066c9cc2..a4d13984f575 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/order.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/order.py
@@ -19,8 +19,8 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Order from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Order from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python/petstore_api/models/outer_composite.py
index 2272cc9f4f9c..f02b63d0052e 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/outer_composite.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/outer_composite.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class OuterComposite(BaseModel):
my_number: Optional[StrictFloat] = None
my_string: Optional[StrictStr] = None
my_boolean: Optional[StrictBool] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["my_number", "my_string", "my_boolean"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["my_number", "my_string", "my_boolean"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterComposite from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterComposite from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python/petstore_api/models/outer_object_with_enum_property.py
index dd6a05e25bff..cb47a63cf871 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/outer_object_with_enum_property.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/outer_object_with_enum_property.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.outer_enum import OuterEnum
from petstore_api.models.outer_enum_integer import OuterEnumInteger
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class OuterObjectWithEnumProperty(BaseModel):
""" # noqa: E501
str_value: Optional[OuterEnum] = None
value: OuterEnumInteger
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["str_value", "value"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["str_value", "value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OuterObjectWithEnumProperty from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python/petstore_api/models/parent.py
index 8a9e22c1656d..ef4e59612632 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/parent.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/parent.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class Parent(BaseModel):
"""
Parent
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Parent from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Parent from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python/petstore_api/models/parent_with_optional_dict.py
index 742936312735..3f3c398dd224 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/parent_with_optional_dict.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/parent_with_optional_dict.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.inner_dict_with_property import InnerDictWithProperty
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class ParentWithOptionalDict(BaseModel):
"""
ParentWithOptionalDict
""" # noqa: E501
- optional_dict: Optional[Dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["optionalDict"]
+ optional_dict: Optional[dict[str, InnerDictWithProperty]] = Field(default=None, alias="optionalDict")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["optionalDict"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ParentWithOptionalDict from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python/petstore_api/models/pet.py
index 6d117df625b0..7154fcded7b6 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/pet.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/pet.py
@@ -18,11 +18,11 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
from petstore_api.models.category import Category
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -33,11 +33,11 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
category: Optional[Category] = None
name: StrictStr
- photo_urls: Annotated[List[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: Annotated[list[StrictStr], Field(min_length=0)] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -70,7 +70,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -108,7 +108,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/pig.py b/samples/openapi3/client/petstore/python/petstore_api/models/pig.py
index 06798245b8fe..ee1b3f716534 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/pig.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/pig.py
@@ -16,11 +16,11 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.basque_pig import BasquePig
from petstore_api.models.danish_pig import DanishPig
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
PIG_ONE_OF_SCHEMAS = ["BasquePig", "DanishPig"]
@@ -34,7 +34,7 @@ class Pig(BaseModel):
# data type: DanishPig
oneof_schema_2_validator: Optional[DanishPig] = None
actual_instance: Optional[Union[BasquePig, DanishPig]] = None
- one_of_schemas: Set[str] = { "BasquePig", "DanishPig" }
+ one_of_schemas: set[str] = { "BasquePig", "DanishPig" }
model_config = ConfigDict(
validate_assignment=True,
@@ -42,7 +42,7 @@ class Pig(BaseModel):
)
- discriminator_value_class_map: Dict[str, str] = {
+ discriminator_value_class_map: dict[str, str] = {
}
def __init__(self, *args, **kwargs) -> None:
@@ -80,7 +80,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -137,7 +137,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], BasquePig, DanishPig]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], BasquePig, DanishPig]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python/petstore_api/models/pony_sizes.py
index 4a231ca7cace..03d46f24c69d 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/pony_sizes.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/pony_sizes.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.type import Type
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class PonySizes(BaseModel):
PonySizes
""" # noqa: E501
type: Optional[Type] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["type"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["type"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PonySizes from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PonySizes from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python/petstore_api/models/poop_cleaning.py
index aed809a9fe0b..d96f8de6563e 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/poop_cleaning.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/poop_cleaning.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List
-from typing import Optional, Set
+from typing import Any, ClassVar
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class PoopCleaning(BaseModel):
task_name: StrictStr
function_name: StrictStr
content: StrictStr
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["task_name", "function_name", "content"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["task_name", "function_name", "content"]
@field_validator('task_name')
def task_name_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PoopCleaning from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PoopCleaning from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python/petstore_api/models/primitive_string.py
index 1cee0bb8d9cf..9c16f68c4554 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/primitive_string.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/primitive_string.py
@@ -18,9 +18,9 @@
import json
from pydantic import ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.base_discriminator import BaseDiscriminator
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class PrimitiveString(BaseDiscriminator):
PrimitiveString
""" # noqa: E501
value: Optional[StrictStr] = Field(default=None, alias="_value")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_typeName", "_value"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_typeName", "_value"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PrimitiveString from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PrimitiveString from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python/petstore_api/models/property_map.py
index e72e32123334..87695639bdbd 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/property_map.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/property_map.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.tag import Tag
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class PropertyMap(BaseModel):
"""
PropertyMap
""" # noqa: E501
- some_data: Optional[Dict[str, Tag]] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["some_data"]
+ some_data: Optional[dict[str, Tag]] = None
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["some_data"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyMap from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyMap from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python/petstore_api/models/property_name_collision.py
index 07b4652d12f0..51771d81fa70 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/property_name_collision.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/property_name_collision.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -30,8 +30,8 @@ class PropertyNameCollision(BaseModel):
underscore_type: Optional[StrictStr] = Field(default=None, alias="_type")
type: Optional[StrictStr] = None
type_with_underscore: Optional[StrictStr] = Field(default=None, alias="type_")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_type", "type", "type_"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_type", "type", "type_"]
model_config = ConfigDict(
validate_by_name=True,
@@ -54,7 +54,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -82,7 +82,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of PropertyNameCollision from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python/petstore_api/models/read_only_first.py
index debfe69300dc..de84c323cd34 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/read_only_first.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/read_only_first.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class ReadOnlyFirst(BaseModel):
""" # noqa: E501
bar: Optional[StrictStr] = None
baz: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["bar", "baz"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["bar", "baz"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -65,7 +65,7 @@ def to_dict(self) -> Dict[str, Any]:
* OpenAPI `readOnly` fields are excluded.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"bar",
"additional_properties",
])
@@ -83,7 +83,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of ReadOnlyFirst from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python/petstore_api/models/second_circular_all_of_ref.py
index 19116213fd5d..bc0976bf88a9 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/second_circular_all_of_ref.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/second_circular_all_of_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class SecondCircularAllOfRef(BaseModel):
SecondCircularAllOfRef
""" # noqa: E501
name: Optional[StrictStr] = Field(default=None, alias="_name")
- circular_all_of_ref: Optional[List[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["_name", "circularAllOfRef"]
+ circular_all_of_ref: Optional[list[CircularAllOfRef]] = Field(default=None, alias="circularAllOfRef")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["_name", "circularAllOfRef"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -88,7 +88,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondCircularAllOfRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python/petstore_api/models/second_ref.py
index ef17a11429a9..fe83233f02cc 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/second_ref.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/second_ref.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class SecondRef(BaseModel):
""" # noqa: E501
category: Optional[StrictStr] = None
circular_ref: Optional[CircularReferenceModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["category", "circular_ref"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["category", "circular_ref"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SecondRef from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SecondRef from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python/petstore_api/models/self_reference_model.py
index bd49a84093b5..50643b4782eb 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/self_reference_model.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/self_reference_model.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class SelfReferenceModel(BaseModel):
""" # noqa: E501
size: Optional[StrictInt] = None
nested: Optional[DummyModel] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -84,7 +84,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SelfReferenceModel from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python/petstore_api/models/special_model_name.py
index 528c09f6c18f..43d77bb2f06b 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/special_model_name.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/special_model_name.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class SpecialModelName(BaseModel):
SpecialModelName
""" # noqa: E501
special_property_name: Optional[StrictInt] = Field(default=None, alias="$special[property.name]")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["$special[property.name]"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["$special[property.name]"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialModelName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialModelName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python/petstore_api/models/special_name.py
index c667d1e9e4c6..c7a24fdba835 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/special_name.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/special_name.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.category import Category
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class SpecialName(BaseModel):
var_property: Optional[StrictInt] = Field(default=None, alias="property")
var_async: Optional[Category] = Field(default=None, alias="async")
var_schema: Optional[StrictStr] = Field(default=None, description="pet status in the store", alias="schema")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["property", "async", "schema"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["property", "async", "schema"]
@field_validator('var_schema')
def var_schema_validate_enum(cls, value):
@@ -65,7 +65,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of SpecialName from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of SpecialName from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python/petstore_api/models/tag.py
index 7b636a76d02e..6ff1efaa4e70 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/tag.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/tag.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/task.py b/samples/openapi3/client/petstore/python/petstore_api/models/task.py
index b7a3153d1ea5..5c6d4d998895 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/task.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/task.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict
-from typing import Any, ClassVar, Dict, List
+from typing import Any, ClassVar
from uuid import UUID
from petstore_api.models.task_activity import TaskActivity
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -31,8 +31,8 @@ class Task(BaseModel):
""" # noqa: E501
id: UUID
activity: TaskActivity
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "activity"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "activity"]
model_config = ConfigDict(
validate_by_name=True,
@@ -55,7 +55,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Task from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -66,7 +66,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Task from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/task_activity.py b/samples/openapi3/client/petstore/python/petstore_api/models/task_activity.py
index cc1e1fc5a60f..51bec8a6c3f0 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/task_activity.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/task_activity.py
@@ -16,12 +16,12 @@
import json
import pprint
from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator
-from typing import Any, List, Optional
+from typing import Any, Optional
from petstore_api.models.bathing import Bathing
from petstore_api.models.feeding import Feeding
from petstore_api.models.poop_cleaning import PoopCleaning
from pydantic import StrictStr, Field
-from typing import Union, List, Set, Optional, Dict
+from typing import Union, Optional
from typing_extensions import Literal, Self
TASKACTIVITY_ONE_OF_SCHEMAS = ["Bathing", "Feeding", "PoopCleaning"]
@@ -37,7 +37,7 @@ class TaskActivity(BaseModel):
# data type: Bathing
oneof_schema_3_validator: Optional[Bathing] = None
actual_instance: Optional[Union[Bathing, Feeding, PoopCleaning]] = None
- one_of_schemas: Set[str] = { "Bathing", "Feeding", "PoopCleaning" }
+ one_of_schemas: set[str] = { "Bathing", "Feeding", "PoopCleaning" }
model_config = ConfigDict(
validate_assignment=True,
@@ -85,7 +85,7 @@ def actual_instance_must_validate_oneof(cls, v):
return v
@classmethod
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
+ def from_dict(cls, obj: Union[str, dict[str, Any]]) -> Self:
return cls.from_json(json.dumps(obj))
@classmethod
@@ -133,7 +133,7 @@ def to_json(self) -> str:
else:
return json.dumps(self.actual_instance)
- def to_dict(self) -> Optional[Union[Dict[str, Any], Bathing, Feeding, PoopCleaning]]:
+ def to_dict(self) -> Optional[Union[dict[str, Any], Bathing, Feeding, PoopCleaning]]:
"""Returns the dict representation of the actual instance"""
if self.actual_instance is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model400_response.py
index 6c4ac684baeb..a1f14e8a2173 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model400_response.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model400_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestErrorResponsesWithModel400Response(BaseModel):
TestErrorResponsesWithModel400Response
""" # noqa: E501
reason400: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["reason400"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["reason400"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel400Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model404_response.py
index 225e27ea0789..5166582c4c11 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model404_response.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/test_error_responses_with_model404_response.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestErrorResponsesWithModel404Response(BaseModel):
TestErrorResponsesWithModel404Response
""" # noqa: E501
reason404: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["reason404"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["reason404"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestErrorResponsesWithModel404Response from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/test_inline_freeform_additional_properties_request.py b/samples/openapi3/client/petstore/python/petstore_api/models/test_inline_freeform_additional_properties_request.py
index 67f893c75448..2ba526ab52ba 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/test_inline_freeform_additional_properties_request.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/test_inline_freeform_additional_properties_request.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestInlineFreeformAdditionalPropertiesRequest(BaseModel):
TestInlineFreeformAdditionalPropertiesRequest
""" # noqa: E501
some_property: Optional[StrictStr] = Field(default=None, alias="someProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["someProperty"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["someProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestInlineFreeformAdditionalPropertiesRequest from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python/petstore_api/models/test_model_with_enum_default.py
index cce5ffb967e7..cc4d8ce59ae2 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/test_model_with_enum_default.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/test_model_with_enum_default.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.test_enum import TestEnum
from petstore_api.models.test_enum_with_default import TestEnumWithDefault
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -34,8 +34,8 @@ class TestModelWithEnumDefault(BaseModel):
test_enum_with_default: Optional[TestEnumWithDefault] = TestEnumWithDefault.ZWEI
test_string_with_default: Optional[StrictStr] = 'ahoy matey'
test_inline_defined_enum_with_default: Optional[StrictStr] = 'B'
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["test_enum", "test_string", "test_enum_with_default", "test_string_with_default", "test_inline_defined_enum_with_default"]
@field_validator('test_inline_defined_enum_with_default')
def test_inline_defined_enum_with_default_validate_enum(cls, value):
@@ -68,7 +68,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -79,7 +79,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -96,7 +96,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestModelWithEnumDefault from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python/petstore_api/models/test_object_for_multipart_requests_request_marker.py
index 33bf3764d782..b9bc9abd1e97 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/test_object_for_multipart_requests_request_marker.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/test_object_for_multipart_requests_request_marker.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class TestObjectForMultipartRequestsRequestMarker(BaseModel):
TestObjectForMultipartRequestsRequestMarker
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of TestObjectForMultipartRequestsRequestMarker from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python/petstore_api/models/tiger.py
index 0962151b05ba..4fce3fe90fb6 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/tiger.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/tiger.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class Tiger(BaseModel):
Tiger
""" # noqa: E501
skill: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["skill"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["skill"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of Tiger from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of Tiger from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
index cf6878baa1b9..1559c48ddb2c 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, Field
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.creature_info import CreatureInfo
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,9 +28,9 @@ class UnnamedDictWithAdditionalModelListProperties(BaseModel):
"""
UnnamedDictWithAdditionalModelListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[CreatureInfo]]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[CreatureInfo]]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -53,7 +53,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -64,7 +64,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalModelListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
index 9e096d408cb6..b1ed33be0977 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -27,9 +27,9 @@ class UnnamedDictWithAdditionalStringListProperties(BaseModel):
"""
UnnamedDictWithAdditionalStringListProperties
""" # noqa: E501
- dict_property: Optional[Dict[str, List[StrictStr]]] = Field(default=None, alias="dictProperty")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["dictProperty"]
+ dict_property: Optional[dict[str, list[StrictStr]]] = Field(default=None, alias="dictProperty")
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["dictProperty"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UnnamedDictWithAdditionalStringListProperties from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python/petstore_api/models/upload_file_with_additional_properties_request_object.py
index 1fd25f6d3f7b..116c7434234d 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/upload_file_with_additional_properties_request_object.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/upload_file_with_additional_properties_request_object.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -28,8 +28,8 @@ class UploadFileWithAdditionalPropertiesRequestObject(BaseModel):
Additional object
""" # noqa: E501
name: Optional[StrictStr] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["name"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["name"]
model_config = ConfigDict(
validate_by_name=True,
@@ -52,7 +52,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -63,7 +63,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -80,7 +80,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UploadFileWithAdditionalPropertiesRequestObject from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/user.py b/samples/openapi3/client/petstore/python/petstore_api/models/user.py
index d0c58815f3ce..21a278fc5a54 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/user.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/user.py
@@ -18,8 +18,8 @@
import json
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
-from typing import Optional, Set
+from typing import Any, ClassVar, Optional
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -35,8 +35,8 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, description="User Status", alias="userStatus")
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
model_config = ConfigDict(
validate_by_name=True,
@@ -59,7 +59,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of User from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -70,7 +70,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -87,7 +87,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of User from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/uuid_with_pattern.py b/samples/openapi3/client/petstore/python/petstore_api/models/uuid_with_pattern.py
index e86c87f16359..cb00d5375e4e 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/uuid_with_pattern.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/uuid_with_pattern.py
@@ -18,9 +18,9 @@
import json
from pydantic import BaseModel, ConfigDict, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from uuid import UUID
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -29,8 +29,8 @@ class UuidWithPattern(BaseModel):
UuidWithPattern
""" # noqa: E501
id: Optional[UUID] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["id"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["id"]
@field_validator('id')
def id_validate_regular_expression(cls, value):
@@ -66,7 +66,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -94,7 +94,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of UuidWithPattern from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python/petstore_api/models/with_nested_one_of.py
index d3127ac468c0..54ecffec4ac6 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/models/with_nested_one_of.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/models/with_nested_one_of.py
@@ -18,10 +18,10 @@
import json
from pydantic import BaseModel, ConfigDict, StrictInt
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from petstore_api.models.one_of_enum_string import OneOfEnumString
from petstore_api.models.pig import Pig
-from typing import Optional, Set
+from typing import Optional
from typing_extensions import Self
from pydantic_core import to_jsonable_python
@@ -32,8 +32,8 @@ class WithNestedOneOf(BaseModel):
size: Optional[StrictInt] = None
nested_pig: Optional[Pig] = None
nested_oneof_enum_string: Optional[OneOfEnumString] = None
- additional_properties: Dict[str, Any] = {}
- __properties: ClassVar[List[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
+ additional_properties: dict[str, Any] = {}
+ __properties: ClassVar[list[str]] = ["size", "nested_pig", "nested_oneof_enum_string"]
model_config = ConfigDict(
validate_by_name=True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -67,7 +67,7 @@ def to_dict(self) -> Dict[str, Any]:
are ignored.
* Fields in `self.additional_properties` are added to the output dict.
"""
- excluded_fields: Set[str] = set([
+ excluded_fields: set[str] = set([
"additional_properties",
])
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ def from_dict(cls, obj: Optional[dict[str, Any]]) -> Optional[Self]:
"""Create an instance of WithNestedOneOf from a dict"""
if obj is None:
return None
diff --git a/samples/openapi3/client/petstore/python/petstore_api/signing.py b/samples/openapi3/client/petstore/python/petstore_api/signing.py
index e0ef058f4677..c52fe689fc96 100644
--- a/samples/openapi3/client/petstore/python/petstore_api/signing.py
+++ b/samples/openapi3/client/petstore/python/petstore_api/signing.py
@@ -22,7 +22,7 @@
import os
import re
from time import time
-from typing import List, Optional, Union
+from typing import Optional, Union
from urllib.parse import urlencode, urlparse
# The constants below define a subset of HTTP headers that can be included in the
@@ -128,7 +128,7 @@ def __init__(self,
signing_scheme: str,
private_key_path: str,
private_key_passphrase: Union[None, str]=None,
- signed_headers: Optional[List[str]]=None,
+ signed_headers: Optional[list[str]]=None,
signing_algorithm: Optional[str]=None,
hash_algorithm: Optional[str]=None,
signature_max_validity: Optional[timedelta]=None,
diff --git a/samples/openapi3/client/petstore/python/tests/test_deserialization.py b/samples/openapi3/client/petstore/python/tests/test_deserialization.py
index a8ebc21126cd..52f19bd78e7a 100644
--- a/samples/openapi3/client/petstore/python/tests/test_deserialization.py
+++ b/samples/openapi3/client/petstore/python/tests/test_deserialization.py
@@ -28,7 +28,7 @@ def setUp(self):
self.deserialize = self.api_client.deserialize
def test_enum_test(self):
- """ deserialize Dict[str, EnumTest] """
+ """ deserialize dict[str, EnumTest] """
data = {
'enum_test': {
"enum_string": "UPPER",
@@ -40,7 +40,7 @@ def test_enum_test(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, EnumTest]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, EnumTest]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['enum_test'], petstore_api.EnumTest))
self.assertEqual(deserialized['enum_test'],
@@ -51,7 +51,7 @@ def test_enum_test(self):
outerEnum=petstore_api.OuterEnum.PLACED))
def test_deserialize_dict_str_pet(self):
- """ deserialize Dict[str, Pet] """
+ """ deserialize dict[str, Pet] """
data = {
'pet': {
"id": 0,
@@ -74,13 +74,13 @@ def test_deserialize_dict_str_pet(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, Pet]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, Pet]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['pet'], petstore_api.Pet))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_dog(self):
- """ deserialize Dict[str, Animal], use discriminator"""
+ """ deserialize dict[str, Animal], use discriminator"""
data = {
'dog': {
"id": 0,
@@ -91,19 +91,19 @@ def test_deserialize_dict_str_dog(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, Animal]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, Animal]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['dog'], petstore_api.Dog))
@pytest.mark.skip(reason="skipping for now as deserialization will be refactored")
def test_deserialize_dict_str_int(self):
- """ deserialize Dict[str, int] """
+ """ deserialize dict[str, int] """
data = {
'integer': 1
}
response = json.dumps(data)
- deserialized = self.deserialize(response, 'Dict[str, int]', 'application/json')
+ deserialized = self.deserialize(response, 'dict[str, int]', 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized['integer'], int))
@@ -212,7 +212,7 @@ def test_deserialize_list_of_pet(self):
}]
response = json.dumps(data)
- deserialized = self.deserialize(response, "List[Pet]", 'application/json')
+ deserialized = self.deserialize(response, "list[Pet]", 'application/json')
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], petstore_api.Pet))
self.assertEqual(deserialized[0].id, 0)
@@ -221,7 +221,7 @@ def test_deserialize_list_of_pet(self):
self.assertEqual(deserialized[1].name, "doggie1")
def test_deserialize_nested_dict(self):
- """ deserialize Dict[str, Dict[str, int]] """
+ """ deserialize dict[str, dict[str, int]] """
data = {
"foo": {
"bar": 1
@@ -229,7 +229,7 @@ def test_deserialize_nested_dict(self):
}
response = json.dumps(data)
- deserialized = self.deserialize(response, "Dict[str, Dict[str, int]]", 'application/json')
+ deserialized = self.deserialize(response, "dict[str, dict[str, int]]", 'application/json')
self.assertTrue(isinstance(deserialized, dict))
self.assertTrue(isinstance(deserialized["foo"], dict))
self.assertTrue(isinstance(deserialized["foo"]["bar"], int))
@@ -239,7 +239,7 @@ def test_deserialize_nested_list(self):
data = [["foo"]]
response = json.dumps(data)
- deserialized = self.deserialize(response, "List[List[str]]", 'application/json')
+ deserialized = self.deserialize(response, "list[list[str]]", 'application/json')
self.assertTrue(isinstance(deserialized, list))
self.assertTrue(isinstance(deserialized[0], list))
self.assertTrue(isinstance(deserialized[0][0], str))
@@ -311,18 +311,18 @@ def test_deserialize_content_type(self):
response = json.dumps({"a": "a"})
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/json')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/vnd.api+json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/vnd.api+json')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/json; charset=utf-8')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/json; charset=utf-8')
self.assertTrue(isinstance(deserialized, dict))
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/vnd.api+json; charset=utf-8')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/vnd.api+json; charset=utf-8')
self.assertTrue(isinstance(deserialized, dict))
deserialized = self.deserialize(response, "str", 'text/plain')
@@ -331,7 +331,7 @@ def test_deserialize_content_type(self):
deserialized = self.deserialize(response, "str", 'text/csv')
self.assertTrue(isinstance(deserialized, str))
- deserialized = self.deserialize(response, "Dict[str, str]", 'APPLICATION/JSON')
+ deserialized = self.deserialize(response, "dict[str, str]", 'APPLICATION/JSON')
self.assertTrue(isinstance(deserialized, dict))
with self.assertRaises(petstore_api.ApiException) as cm:
@@ -341,8 +341,8 @@ def test_deserialize_content_type(self):
deserialized = self.deserialize(response, "str", 'text/n0t-exist!ng')
with self.assertRaises(petstore_api.ApiException) as cm:
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/jsonnnnn')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/jsonnnnn')
with self.assertRaises(petstore_api.ApiException) as cm:
- deserialized = self.deserialize(response, "Dict[str, str]", 'application/<+json')
+ deserialized = self.deserialize(response, "dict[str, str]", 'application/<+json')
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Address.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Address.h
index eaf778a713e4..f3e347cc274c 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Address.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Address.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Animal.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Animal.h
index e3f179bc7196..1627b95f9ab7 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Animal.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Animal.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/ArrayTypes.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/ArrayTypes.h
index ce247d827611..ca06187b6d11 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/ArrayTypes.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/ArrayTypes.h
@@ -7,9 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
-#include
#include "SimpleObject.h"
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/BankAccount.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/BankAccount.h
index e5d88115e447..17d010bd35b4 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/BankAccount.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/BankAccount.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Company.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Company.h
index acb61e0db444..db4e322d0ecc 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Company.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Company.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
#include "Address.h"
#include "Department.h"
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/CreatedResponse.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/CreatedResponse.h
index b3f94e4cec83..7b7f8f71b341 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/CreatedResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/CreatedResponse.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/CreditCard.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/CreditCard.h
index f53af49ef132..aa695ca2143c 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/CreditCard.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/CreditCard.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Department.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Department.h
index fa133c2bed92..3155f36b3186 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Department.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Department.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
#include "Employee.h"
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Dog.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Dog.h
index fc075c18b8bd..2de45ec00ec7 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Dog.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Dog.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
// Project headers
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/Employee.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/Employee.h
index 1a7bb642a773..ec7ccb728aec 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/Employee.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/Employee.h
@@ -7,9 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
-#include
#include "Address.h"
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/EnumTypes.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/EnumTypes.h
index 6ea087bf17e3..83e96d3ea073 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/EnumTypes.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/EnumTypes.h
@@ -8,8 +8,6 @@
// System headers
#include
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/ErrorResponse.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/ErrorResponse.h
index 72f143d780e9..a66c313c50aa 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/ErrorResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/ErrorResponse.h
@@ -7,9 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/NotFoundResponse.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/NotFoundResponse.h
index 9b209b5d3f2e..be3c18a33cdd 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/NotFoundResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/NotFoundResponse.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/NullableOptionalTypes.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/NullableOptionalTypes.h
index 7e5df57ad443..b5bc84f1792d 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/NullableOptionalTypes.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/NullableOptionalTypes.h
@@ -8,8 +8,6 @@
// System headers
#include
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/PaymentMethod.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/PaymentMethod.h
index 0f5d86c9fae5..e90edf1112b0 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/PaymentMethod.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/PaymentMethod.h
@@ -8,7 +8,6 @@
// System headers
#include
#include
-#include
#include "BankAccount.h"
#include "CreditCard.h"
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/PrimitiveTypes.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/PrimitiveTypes.h
index 89894663074b..12032883e46f 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/PrimitiveTypes.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/PrimitiveTypes.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/SimpleObject.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/SimpleObject.h
index eae83fbbe860..cafc587703e7 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/SimpleObject.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/SimpleObject.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/SuccessResponse.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/SuccessResponse.h
index a6de84bce543..5bc8252e9f79 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/SuccessResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/SuccessResponse.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestAllParameterTypes200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestAllParameterTypes200Response.h
index ce9ade6be871..75171757037a 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestAllParameterTypes200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestAllParameterTypes200Response.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestApiKeySecurity200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestApiKeySecurity200Response.h
index f2ebdc38cc2d..dd11ebea21cf 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestApiKeySecurity200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestApiKeySecurity200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBasicSecurity200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBasicSecurity200Response.h
index c2a923e72215..8a7023e0e1ed 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBasicSecurity200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBasicSecurity200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBearerSecurity200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBearerSecurity200Response.h
index 0cb7cbe8421d..c4f2880e5502 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBearerSecurity200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestBearerSecurity200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestCookieParameters200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestCookieParameters200Response.h
index a5548cc28b0d..85d07e547d38 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestCookieParameters200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestCookieParameters200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters200Response.h
index cb091980a63d..6ed2c23b6760 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters401Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters401Response.h
index 7b6e0d5ed738..837ed2299617 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters401Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestHeaderParameters401Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestOAuth2Security200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestOAuth2Security200Response.h
index 8e232d4866a2..9995544f6f44 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestOAuth2Security200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestOAuth2Security200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParameters200Response.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParameters200Response.h
index 7b7b05c4d919..64b727546ed8 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParameters200Response.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParameters200Response.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParametersDeepObjectParameter.h b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParametersDeepObjectParameter.h
index 76d6f4edeaea..1a4e6317d707 100644
--- a/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParametersDeepObjectParameter.h
+++ b/samples/server/petstore/cpp-httplib-server/feature-test/models/TestQueryParametersDeepObjectParameter.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/ApiResponse.h b/samples/server/petstore/cpp-httplib-server/petstore/models/ApiResponse.h
index 3cb5f3ed9df6..b8367296ee07 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/ApiResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/ApiResponse.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/Category.h b/samples/server/petstore/cpp-httplib-server/petstore/models/Category.h
index 432674c5607b..2e098b98f712 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/Category.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/Category.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/ComplexParamsResponse.h b/samples/server/petstore/cpp-httplib-server/petstore/models/ComplexParamsResponse.h
index eaab72300df9..1be2d497b3bd 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/ComplexParamsResponse.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/ComplexParamsResponse.h
@@ -8,9 +8,6 @@
// System headers
#include
#include
-#include
-#include
-#include
#include "DeepObj.h"
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObj.h b/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObj.h
index 25350d579e94..8c8479d97a0d 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObj.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObj.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
#include "DeepObjBaz.h"
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObjBaz.h b/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObjBaz.h
index 5220c128694b..ade2f3aa20aa 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObjBaz.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/DeepObjBaz.h
@@ -7,8 +7,6 @@
#pragma once
// System headers
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/NullableExample.h b/samples/server/petstore/cpp-httplib-server/petstore/models/NullableExample.h
index cd532bccb1b8..4b13f1b7999e 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/NullableExample.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/NullableExample.h
@@ -8,7 +8,6 @@
// System headers
#include
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/Order.h b/samples/server/petstore/cpp-httplib-server/petstore/models/Order.h
index 7e7d3aade171..4d2876566fb9 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/Order.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/Order.h
@@ -8,8 +8,6 @@
// System headers
#include
#include
-#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/Pet.h b/samples/server/petstore/cpp-httplib-server/petstore/models/Pet.h
index a120edbd44fc..5059931f43e6 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/Pet.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/Pet.h
@@ -8,8 +8,6 @@
// System headers
#include
#include
-#include
-#include
#include "Category.h"
#include "Tag.h"
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/PetOrCategory.h b/samples/server/petstore/cpp-httplib-server/petstore/models/PetOrCategory.h
index 395dfafc31ba..302f66ba8f1d 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/PetOrCategory.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/PetOrCategory.h
@@ -9,8 +9,6 @@
#include
#include
#include
-#include
-#include
#include "Category.h"
#include "Pet.h"
#include "Tag.h"
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/Tag.h b/samples/server/petstore/cpp-httplib-server/petstore/models/Tag.h
index d8255563cdeb..b948ad3594dc 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/Tag.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/Tag.h
@@ -7,7 +7,6 @@
#pragma once
// System headers
#include
-#include
diff --git a/samples/server/petstore/cpp-httplib-server/petstore/models/User.h b/samples/server/petstore/cpp-httplib-server/petstore/models/User.h
index ca4e9d5ff0de..568ebe244bd8 100644
--- a/samples/server/petstore/cpp-httplib-server/petstore/models/User.h
+++ b/samples/server/petstore/cpp-httplib-server/petstore/models/User.h
@@ -8,8 +8,6 @@
// System headers
#include
#include
-#include
-#include
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/pet_controller.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/pet_controller.py
index ad7557832bab..d1f5cd262e27 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/pet_controller.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/pet_controller.py
@@ -1,4 +1,3 @@
-from typing import List, Dict
from aiohttp import web
from openapi_server.models.api_response import ApiResponse
@@ -39,7 +38,7 @@ async def find_pets_by_status(request: web.Request, status) -> web.Response:
Multiple status values can be provided with comma separated strings
:param status: Status values that need to be considered for filter
- :type status: List[str]
+ :type status: list[str]
"""
return web.Response(status=200)
@@ -51,7 +50,7 @@ async def find_pets_by_tags(request: web.Request, tags) -> web.Response:
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
:param tags: Tags to filter by
- :type tags: List[str]
+ :type tags: list[str]
"""
return web.Response(status=200)
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/security_controller.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/security_controller.py
index 82a8ffedab35..988c915ae301 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/security_controller.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/security_controller.py
@@ -1,5 +1,3 @@
-from typing import List
-
def info_from_petstore_auth(token: str) -> dict:
"""
@@ -12,7 +10,7 @@ def info_from_petstore_auth(token: str) -> dict:
return {'scopes': ['read:pets', 'write:pets'], 'uid': 'user_id'}
-def validate_scope_petstore_auth(required_scopes: List[str], token_scopes: List[str]) -> bool:
+def validate_scope_petstore_auth(required_scopes: list[str], token_scopes: list[str]) -> bool:
""" Validate required scopes are included in token scope """
return set(required_scopes).issubset(set(token_scopes))
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/store_controller.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/store_controller.py
index 38792ced264b..dc3dfeb0efc5 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/store_controller.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/store_controller.py
@@ -1,4 +1,3 @@
-from typing import List, Dict
from aiohttp import web
from openapi_server.models.order import Order
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/user_controller.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/user_controller.py
index 89dd08724136..2d62f205e06a 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/user_controller.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/controllers/user_controller.py
@@ -1,4 +1,3 @@
-from typing import List, Dict
from aiohttp import web
from openapi_server.models.user import User
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/api_response.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/api_response.py
index 1ee9b143c962..1592fd2b96f8 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/api_response.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/api_response.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/category.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/category.py
index f4fd3dde80b1..a2163405542d 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/category.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/category.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/order.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/order.py
index 6fab59c0350c..8ee41996653c 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/order.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/order.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/pet.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/pet.py
index 8b4fcb126de5..23b11d0aa9bb 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/pet.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/pet.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server.models.category import Category
from openapi_server.models.tag import Tag
@@ -16,7 +14,7 @@ class Pet(Model):
Do not edit the class manually.
"""
- def __init__(self, id: int=None, category: Category=None, name: str=None, photo_urls: List[str]=None, tags: List[Tag]=None, status: str=None):
+ def __init__(self, id: int=None, category: Category=None, name: str=None, photo_urls: list[str]=None, tags: list[Tag]=None, status: str=None):
"""Pet - a model defined in OpenAPI
:param id: The id of this Pet.
@@ -30,8 +28,8 @@ def __init__(self, id: int=None, category: Category=None, name: str=None, photo_
'id': int,
'category': Category,
'name': str,
- 'photo_urls': List[str],
- 'tags': List[Tag],
+ 'photo_urls': list[str],
+ 'tags': list[Tag],
'status': str
}
@@ -131,7 +129,7 @@ def photo_urls(self):
:return: The photo_urls of this Pet.
- :rtype: List[str]
+ :rtype: list[str]
"""
return self._photo_urls
@@ -141,7 +139,7 @@ def photo_urls(self, photo_urls):
:param photo_urls: The photo_urls of this Pet.
- :type photo_urls: List[str]
+ :type photo_urls: list[str]
"""
if photo_urls is None:
raise ValueError("Invalid value for `photo_urls`, must not be `None`")
@@ -154,7 +152,7 @@ def tags(self):
:return: The tags of this Pet.
- :rtype: List[Tag]
+ :rtype: list[Tag]
"""
return self._tags
@@ -164,7 +162,7 @@ def tags(self, tags):
:param tags: The tags of this Pet.
- :type tags: List[Tag]
+ :type tags: list[Tag]
"""
self._tags = tags
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/tag.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/tag.py
index b26cfe75909f..df020a8e90f8 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/tag.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/tag.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/user.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/user.py
index 6fdcd455e776..4e38b0eb9d9f 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/user.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/models/user.py
@@ -2,8 +2,6 @@
from datetime import date, datetime
-from typing import List, Dict, Type
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/typing_utils.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/typing_utils.py
index 0563f81fd534..9b3eabf41907 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/typing_utils.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/typing_utils.py
@@ -10,11 +10,11 @@ def is_generic(klass):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -24,9 +24,9 @@ def is_generic(klass):
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list
diff --git a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/util.py b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/util.py
index c446943677ea..f793184e7705 100644
--- a/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/util.py
+++ b/samples/server/petstore/python-aiohttp-srclayout/src/openapi_server/util.py
@@ -5,7 +5,7 @@
from openapi_server import typing_utils
T = typing.TypeVar('T')
-Class = typing.Type[T]
+Class = type[T]
def _deserialize(data: Union[dict, list, str], klass: Union[Class, str]) -> Union[dict, list, Class, int, float, str, bool, datetime.date, datetime.datetime]:
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/pet_controller.py b/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/pet_controller.py
index 9a6239dc04d5..2b51eb94836b 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/pet_controller.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/pet_controller.py
@@ -41,9 +41,9 @@ def find_pets_by_status(status): # noqa: E501
Multiple status values can be provided with comma separated strings # noqa: E501
:param status: Status values that need to be considered for filter
- :type status: List[str]
+ :type status: list[str]
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
return 'do some magic!'
@@ -54,9 +54,9 @@ def find_pets_by_tags(tags): # noqa: E501
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
:param tags: Tags to filter by
- :type tags: List[str]
+ :type tags: list[str]
- :rtype: List[Pet]
+ :rtype: list[Pet]
"""
return 'do some magic!'
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/store_controller.py b/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/store_controller.py
index e1ae58967c58..ce2491a45379 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/store_controller.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/controllers/store_controller.py
@@ -23,7 +23,7 @@ def get_inventory(): # noqa: E501
Returns a map of status codes to quantities # noqa: E501
- :rtype: Dict[str, int]
+ :rtype: dict[str, int]
"""
return 'do some magic!'
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/api_response.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/api_response.py
index a1e206febf91..2b7711899dc8 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/api_response.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/api_response.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/base_model.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/base_model.py
index db5801aee4a1..2f7c5682fc4a 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/base_model.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/base_model.py
@@ -17,7 +17,7 @@ class Model(object):
attribute_map = {}
@classmethod
- def from_dict(cls: typing.Type[T], dikt) -> T:
+ def from_dict(cls: type[T], dikt) -> T:
"""Returns the dict as a model"""
return util.deserialize_model(dikt, cls)
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/category.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/category.py
index b423c2bc9d9d..bd818037ab72 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/category.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/category.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/order.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/order.py
index dbf5ce956c49..5568a58c57a6 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/order.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/order.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/pet.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/pet.py
index 00f51b6bd758..0ecfea2b620d 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/pet.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/pet.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from app.openapi_server.models.category import Category # noqa: F401,E501
from app.openapi_server.models.tag import Tag # noqa: F401,E501
@@ -17,7 +15,7 @@ class Pet(Model):
Do not edit the class manually.
"""
- def __init__(self, id: int=None, category: Category=None, name: str=None, photo_urls: List[str]=None, tags: List[Tag]=None, status: str=None): # noqa: E501
+ def __init__(self, id: int=None, category: Category=None, name: str=None, photo_urls: list[str]=None, tags: list[Tag]=None, status: str=None): # noqa: E501
"""Pet - a model defined in Swagger
:param id: The id of this Pet. # noqa: E501
@@ -27,9 +25,9 @@ def __init__(self, id: int=None, category: Category=None, name: str=None, photo_
:param name: The name of this Pet. # noqa: E501
:type name: str
:param photo_urls: The photo_urls of this Pet. # noqa: E501
- :type photo_urls: List[str]
+ :type photo_urls: list[str]
:param tags: The tags of this Pet. # noqa: E501
- :type tags: List[Tag]
+ :type tags: list[Tag]
:param status: The status of this Pet. # noqa: E501
:type status: str
"""
@@ -37,8 +35,8 @@ def __init__(self, id: int=None, category: Category=None, name: str=None, photo_
'id': int,
'category': Category,
'name': str,
- 'photo_urls': List[str],
- 'tags': List[Tag],
+ 'photo_urls': list[str],
+ 'tags': list[Tag],
'status': str
}
@@ -135,22 +133,22 @@ def name(self, name: str):
self._name = name
@property
- def photo_urls(self) -> List[str]:
+ def photo_urls(self) -> list[str]:
"""Gets the photo_urls of this Pet.
:return: The photo_urls of this Pet.
- :rtype: List[str]
+ :rtype: list[str]
"""
return self._photo_urls
@photo_urls.setter
- def photo_urls(self, photo_urls: List[str]):
+ def photo_urls(self, photo_urls: list[str]):
"""Sets the photo_urls of this Pet.
:param photo_urls: The photo_urls of this Pet.
- :type photo_urls: List[str]
+ :type photo_urls: list[str]
"""
if photo_urls is None:
raise ValueError("Invalid value for `photo_urls`, must not be `None`") # noqa: E501
@@ -158,22 +156,22 @@ def photo_urls(self, photo_urls: List[str]):
self._photo_urls = photo_urls
@property
- def tags(self) -> List[Tag]:
+ def tags(self) -> list[Tag]:
"""Gets the tags of this Pet.
:return: The tags of this Pet.
- :rtype: List[Tag]
+ :rtype: list[Tag]
"""
return self._tags
@tags.setter
- def tags(self, tags: List[Tag]):
+ def tags(self, tags: list[Tag]):
"""Sets the tags of this Pet.
:param tags: The tags of this Pet.
- :type tags: List[Tag]
+ :type tags: list[Tag]
"""
self._tags = tags
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/tag.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/tag.py
index e89e96e6927d..12a6a293086d 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/tag.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/tag.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/models/user.py b/samples/server/petstore/python-blueplanet/app/openapi_server/models/user.py
index 603e43122441..966b58580602 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/models/user.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/models/user.py
@@ -3,8 +3,6 @@
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from app.openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-blueplanet/app/openapi_server/typing_utils.py b/samples/server/petstore/python-blueplanet/app/openapi_server/typing_utils.py
index 0563f81fd534..9b3eabf41907 100644
--- a/samples/server/petstore/python-blueplanet/app/openapi_server/typing_utils.py
+++ b/samples/server/petstore/python-blueplanet/app/openapi_server/typing_utils.py
@@ -10,11 +10,11 @@ def is_generic(klass):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -24,9 +24,9 @@ def is_generic(klass):
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api.py
index 0e3f8d51b319..96de634f5949 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api.py
@@ -1,6 +1,5 @@
# coding: utf-8
-from typing import Dict, List # noqa: F401
import importlib
import pkgutil
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api_base.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api_base.py
index 1c71537aa944..376b4201985a 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api_base.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/fake_api_base.py
@@ -1,6 +1,6 @@
# coding: utf-8
-from typing import ClassVar, Dict, List, Tuple # noqa: F401
+from typing import ClassVar
from pydantic import Field, StrictStr
from typing import Any, Optional
@@ -8,7 +8,7 @@
class BaseFakeApi:
- subclasses: ClassVar[Tuple] = ()
+ subclasses: ClassVar[tuple] = ()
def __init_subclass__(cls, **kwargs):
super().__init_subclass__(**kwargs)
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api.py
index 416272bcd61d..4f002275b696 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api.py
@@ -1,6 +1,5 @@
# coding: utf-8
-from typing import Dict, List # noqa: F401
import importlib
import pkgutil
@@ -24,7 +23,7 @@
from openapi_server.models.extra_models import TokenModel # noqa: F401
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from openapi_server.models.api_response import ApiResponse
from openapi_server.models.pet import Pet
@@ -86,7 +85,7 @@ async def add_pet(
@router.get(
"/pet/findByStatus",
responses={
- 200: {"model": List[Pet], "description": "successful operation"},
+ 200: {"model": list[Pet], "description": "successful operation"},
400: {"description": "Invalid status value"},
},
tags=["pet"],
@@ -94,11 +93,11 @@ async def add_pet(
response_model_by_alias=True,
)
async def find_pets_by_status(
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")] = Query(None, description="Status values that need to be considered for filter", alias="status"),
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")] = Query(None, description="Status values that need to be considered for filter", alias="status"),
token_petstore_auth: TokenModel = Security(
get_token_petstore_auth, scopes=["read:pets"]
),
-) -> List[Pet]:
+) -> list[Pet]:
"""Multiple status values can be provided with comma separated strings"""
if not BasePetApi.subclasses:
raise HTTPException(status_code=500, detail="Not implemented")
@@ -108,7 +107,7 @@ async def find_pets_by_status(
@router.get(
"/pet/findByTags",
responses={
- 200: {"model": List[Pet], "description": "successful operation"},
+ 200: {"model": list[Pet], "description": "successful operation"},
400: {"description": "Invalid tag value"},
},
tags=["pet"],
@@ -116,11 +115,11 @@ async def find_pets_by_status(
response_model_by_alias=True,
)
async def find_pets_by_tags(
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")] = Query(None, description="Tags to filter by", alias="tags"),
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")] = Query(None, description="Tags to filter by", alias="tags"),
token_petstore_auth: TokenModel = Security(
get_token_petstore_auth, scopes=["read:pets"]
),
-) -> List[Pet]:
+) -> list[Pet]:
"""Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing."""
if not BasePetApi.subclasses:
raise HTTPException(status_code=500, detail="Not implemented")
@@ -207,7 +206,7 @@ async def delete_pet(
async def upload_file(
petId: Annotated[StrictInt, Field(description="ID of pet to update")] = Path(..., description="ID of pet to update"),
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")] = Form(None, description="Additional data to pass to server"),
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = Form(None, description="file to upload"),
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")] = Form(None, description="file to upload"),
token_petstore_auth: TokenModel = Security(
get_token_petstore_auth, scopes=["write:pets", "read:pets"]
),
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api_base.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api_base.py
index 0d1fb77e442d..1b0b0e861b66 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api_base.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/pet_api_base.py
@@ -1,16 +1,16 @@
# coding: utf-8
-from typing import ClassVar, Dict, List, Tuple # noqa: F401
+from typing import ClassVar
from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
-from typing import Any, List, Optional, Tuple, Union
+from typing import Any, Optional, Union
from typing_extensions import Annotated
from openapi_server.models.api_response import ApiResponse
from openapi_server.models.pet import Pet
from openapi_server.security_api import get_token_petstore_auth, get_token_api_key
class BasePetApi:
- subclasses: ClassVar[Tuple] = ()
+ subclasses: ClassVar[tuple] = ()
def __init_subclass__(cls, **kwargs):
super().__init_subclass__(**kwargs)
@@ -33,16 +33,16 @@ async def add_pet(
async def find_pets_by_status(
self,
- status: Annotated[List[StrictStr], Field(description="Status values that need to be considered for filter")],
- ) -> List[Pet]:
+ status: Annotated[list[StrictStr], Field(description="Status values that need to be considered for filter")],
+ ) -> list[Pet]:
"""Multiple status values can be provided with comma separated strings"""
...
async def find_pets_by_tags(
self,
- tags: Annotated[List[StrictStr], Field(description="Tags to filter by")],
- ) -> List[Pet]:
+ tags: Annotated[list[StrictStr], Field(description="Tags to filter by")],
+ ) -> list[Pet]:
"""Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing."""
...
@@ -78,7 +78,7 @@ async def upload_file(
self,
petId: Annotated[StrictInt, Field(description="ID of pet to update")],
additional_metadata: Annotated[Optional[StrictStr], Field(description="Additional data to pass to server")],
- file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="file to upload")],
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, tuple[StrictStr, StrictBytes]]], Field(description="file to upload")],
) -> ApiResponse:
""""""
...
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api.py
index 3d2744c2e028..a7b9242ccecf 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api.py
@@ -1,6 +1,5 @@
# coding: utf-8
-from typing import Dict, List # noqa: F401
import importlib
import pkgutil
@@ -24,7 +23,7 @@
from openapi_server.models.extra_models import TokenModel # noqa: F401
from pydantic import Field, StrictInt, StrictStr
-from typing import Any, Dict
+from typing import Any
from typing_extensions import Annotated
from openapi_server.models.order import Order
from openapi_server.security_api import get_token_api_key
@@ -39,7 +38,7 @@
@router.get(
"/store/inventory",
responses={
- 200: {"model": Dict[str, int], "description": "successful operation"},
+ 200: {"model": dict[str, int], "description": "successful operation"},
},
tags=["store"],
summary="Returns pet inventories by status",
@@ -49,7 +48,7 @@ async def get_inventory(
token_api_key: TokenModel = Security(
get_token_api_key
),
-) -> Dict[str, int]:
+) -> dict[str, int]:
"""Returns a map of status codes to quantities"""
if not BaseStoreApi.subclasses:
raise HTTPException(status_code=500, detail="Not implemented")
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api_base.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api_base.py
index 84d9b639c1d3..e3a9907464a2 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api_base.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/store_api_base.py
@@ -1,22 +1,22 @@
# coding: utf-8
-from typing import ClassVar, Dict, List, Tuple # noqa: F401
+from typing import ClassVar
from pydantic import Field, StrictInt, StrictStr
-from typing import Any, Dict
+from typing import Any
from typing_extensions import Annotated
from openapi_server.models.order import Order
from openapi_server.security_api import get_token_api_key
class BaseStoreApi:
- subclasses: ClassVar[Tuple] = ()
+ subclasses: ClassVar[tuple] = ()
def __init_subclass__(cls, **kwargs):
super().__init_subclass__(**kwargs)
BaseStoreApi.subclasses = BaseStoreApi.subclasses + (cls,)
async def get_inventory(
self,
- ) -> Dict[str, int]:
+ ) -> dict[str, int]:
"""Returns a map of status codes to quantities"""
...
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api.py
index e7d5ea8011b5..db8d15fc088b 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api.py
@@ -1,6 +1,5 @@
# coding: utf-8
-from typing import Dict, List # noqa: F401
import importlib
import pkgutil
@@ -24,7 +23,7 @@
from openapi_server.models.extra_models import TokenModel # noqa: F401
from pydantic import Field, StrictStr, field_validator
-from typing import Any, List
+from typing import Any
from typing_extensions import Annotated
from openapi_server.models.user import User
from openapi_server.security_api import get_token_api_key
@@ -67,7 +66,7 @@ async def create_user(
response_model_by_alias=True,
)
async def create_users_with_array_input(
- user: Annotated[List[User], Field(description="List of user object")] = Body(None, description="List of user object"),
+ user: Annotated[list[User], Field(description="List of user object")] = Body(None, description="List of user object"),
token_api_key: TokenModel = Security(
get_token_api_key
),
@@ -88,7 +87,7 @@ async def create_users_with_array_input(
response_model_by_alias=True,
)
async def create_users_with_list_input(
- user: Annotated[List[User], Field(description="List of user object")] = Body(None, description="List of user object"),
+ user: Annotated[list[User], Field(description="List of user object")] = Body(None, description="List of user object"),
token_api_key: TokenModel = Security(
get_token_api_key
),
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api_base.py b/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api_base.py
index 752960411104..bc8de0d9d86c 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api_base.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/apis/user_api_base.py
@@ -1,15 +1,15 @@
# coding: utf-8
-from typing import ClassVar, Dict, List, Tuple # noqa: F401
+from typing import ClassVar
from pydantic import Field, StrictStr, field_validator
-from typing import Any, List
+from typing import Any
from typing_extensions import Annotated
from openapi_server.models.user import User
from openapi_server.security_api import get_token_api_key
class BaseUserApi:
- subclasses: ClassVar[Tuple] = ()
+ subclasses: ClassVar[tuple] = ()
def __init_subclass__(cls, **kwargs):
super().__init_subclass__(**kwargs)
@@ -24,7 +24,7 @@ async def create_user(
async def create_users_with_array_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
) -> None:
""""""
...
@@ -32,7 +32,7 @@ async def create_users_with_array_input(
async def create_users_with_list_input(
self,
- user: Annotated[List[User], Field(description="List of user object")],
+ user: Annotated[list[User], Field(description="List of user object")],
) -> None:
""""""
...
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py
index 441c3b825096..8dba3c946de5 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py
@@ -21,7 +21,7 @@
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
try:
from typing import Self
except ImportError:
@@ -34,7 +34,7 @@ class ApiResponse(BaseModel):
code: Optional[StrictInt] = None
type: Optional[StrictStr] = None
message: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["code", "type", "message"]
+ __properties: ClassVar[list[str]] = ["code", "type", "message"]
model_config = {
"populate_by_name": True,
@@ -57,7 +57,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of ApiResponse from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -76,7 +76,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of ApiResponse from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py
index 48b689cba886..dccc8f5c2fd8 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py
@@ -21,7 +21,7 @@
from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from typing_extensions import Annotated
try:
from typing import Self
@@ -34,7 +34,7 @@ class Category(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[Annotated[str, Field(strict=True)]] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
@field_validator('name')
def name_validate_regular_expression(cls, value):
@@ -67,7 +67,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of Category from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -86,7 +86,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of Category from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py
index 7a5a38cdb7b4..5671855e2fd0 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py
@@ -22,7 +22,7 @@
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
try:
from typing import Self
except ImportError:
@@ -38,7 +38,7 @@ class Order(BaseModel):
ship_date: Optional[datetime] = Field(default=None, alias="shipDate")
status: Optional[StrictStr] = Field(default=None, description="Order Status")
complete: Optional[StrictBool] = False
- __properties: ClassVar[List[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
+ __properties: ClassVar[list[str]] = ["id", "petId", "quantity", "shipDate", "status", "complete"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -71,7 +71,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of Order from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -90,7 +90,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of Order from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py
index 450c1b71393f..ba983f6ce7d6 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py
@@ -21,7 +21,7 @@
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
from openapi_server.models.category import Category
from openapi_server.models.tag import Tag
try:
@@ -36,10 +36,10 @@ class Pet(BaseModel):
id: Optional[StrictInt] = None
category: Optional[Category] = None
name: StrictStr
- photo_urls: List[StrictStr] = Field(alias="photoUrls")
- tags: Optional[List[Tag]] = None
+ photo_urls: list[StrictStr] = Field(alias="photoUrls")
+ tags: Optional[list[Tag]] = None
status: Optional[StrictStr] = Field(default=None, description="pet status in the store")
- __properties: ClassVar[List[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
+ __properties: ClassVar[list[str]] = ["id", "category", "name", "photoUrls", "tags", "status"]
@field_validator('status')
def status_validate_enum(cls, value):
@@ -72,7 +72,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of Pet from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -101,7 +101,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of Pet from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py
index 8b21d362f55c..709c1741a58c 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py
@@ -21,7 +21,7 @@
from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
try:
from typing import Self
except ImportError:
@@ -33,7 +33,7 @@ class Tag(BaseModel):
""" # noqa: E501
id: Optional[StrictInt] = None
name: Optional[StrictStr] = None
- __properties: ClassVar[List[str]] = ["id", "name"]
+ __properties: ClassVar[list[str]] = ["id", "name"]
model_config = {
"populate_by_name": True,
@@ -56,7 +56,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of Tag from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -75,7 +75,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of Tag from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py
index cb98a57479b5..e2692a023051 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py
@@ -21,7 +21,7 @@
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
-from typing import Any, ClassVar, Dict, List, Optional
+from typing import Any, ClassVar, Optional
try:
from typing import Self
except ImportError:
@@ -39,7 +39,7 @@ class User(BaseModel):
password: Optional[StrictStr] = None
phone: Optional[StrictStr] = None
user_status: Optional[StrictInt] = Field(default=None, description="User Status", alias="userStatus")
- __properties: ClassVar[List[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
+ __properties: ClassVar[list[str]] = ["id", "username", "firstName", "lastName", "email", "password", "phone", "userStatus"]
model_config = {
"populate_by_name": True,
@@ -62,7 +62,7 @@ def from_json(cls, json_str: str) -> Self:
"""Create an instance of User from a JSON string"""
return cls.from_dict(json.loads(json_str))
- def to_dict(self) -> Dict[str, Any]:
+ def to_dict(self) -> dict[str, Any]:
"""Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic's
@@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]:
return _dict
@classmethod
- def from_dict(cls, obj: Dict) -> Self:
+ def from_dict(cls, obj: dict) -> Self:
"""Create an instance of User from a dict"""
if obj is None:
return None
diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/security_api.py b/samples/server/petstore/python-fastapi/src/openapi_server/security_api.py
index d216ee4271ea..c7fd9bc9d617 100644
--- a/samples/server/petstore/python-fastapi/src/openapi_server/security_api.py
+++ b/samples/server/petstore/python-fastapi/src/openapi_server/security_api.py
@@ -1,7 +1,5 @@
# coding: utf-8
-from typing import List
-
from fastapi import Depends, Security # noqa: F401
from fastapi.openapi.models import OAuthFlowImplicit, OAuthFlows # noqa: F401
from fastapi.security import ( # noqa: F401
@@ -47,15 +45,15 @@ def get_token_petstore_auth(
def validate_scope_petstore_auth(
- required_scopes: SecurityScopes, token_scopes: List[str]
+ required_scopes: SecurityScopes, token_scopes: list[str]
) -> bool:
"""
Validate required scopes are included in token scope
:param required_scopes Required scope to access called API
- :type required_scopes: List[str]
+ :type required_scopes: list[str]
:param token_scopes Scope present in token
- :type token_scopes: List[str]
+ :type token_scopes: list[str]
:return: True if access to called API is allowed
:rtype: bool
"""
diff --git a/samples/server/petstore/python-flask/openapi_server/controllers/fake_controller.py b/samples/server/petstore/python-flask/openapi_server/controllers/fake_controller.py
index d9847d98d80f..ce50e9c9d53a 100644
--- a/samples/server/petstore/python-flask/openapi_server/controllers/fake_controller.py
+++ b/samples/server/petstore/python-flask/openapi_server/controllers/fake_controller.py
@@ -1,6 +1,4 @@
import connexion
-from typing import Dict
-from typing import Tuple
from typing import Union
from openapi_server import util
@@ -16,6 +14,6 @@ def fake_query_param_default(has_default=None, no_default=None): # noqa: E501
:param no_default: no default value
:type no_default: str
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
diff --git a/samples/server/petstore/python-flask/openapi_server/controllers/pet_controller.py b/samples/server/petstore/python-flask/openapi_server/controllers/pet_controller.py
index dfc5a0251881..bb9ebb8b9545 100644
--- a/samples/server/petstore/python-flask/openapi_server/controllers/pet_controller.py
+++ b/samples/server/petstore/python-flask/openapi_server/controllers/pet_controller.py
@@ -1,6 +1,4 @@
import connexion
-from typing import Dict
-from typing import Tuple
from typing import Union
from openapi_server.models.api_response import ApiResponse # noqa: E501
@@ -16,7 +14,7 @@ def add_pet(body): # noqa: E501
:param pet: Pet object that needs to be added to the store
:type pet: dict | bytes
- :rtype: Union[Pet, Tuple[Pet, int], Tuple[Pet, int, Dict[str, str]]
+ :rtype: Union[Pet, tuple[Pet, int], tuple[Pet, int, dict[str, str]]
"""
pet = body
if connexion.request.is_json:
@@ -34,7 +32,7 @@ def delete_pet(pet_id, api_key=None): # noqa: E501
:param api_key:
:type api_key: str
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
@@ -45,9 +43,9 @@ def find_pets_by_status(status): # noqa: E501
Multiple status values can be provided with comma separated strings # noqa: E501
:param status: Status values that need to be considered for filter
- :type status: List[str]
+ :type status: list[str]
- :rtype: Union[List[Pet], Tuple[List[Pet], int], Tuple[List[Pet], int, Dict[str, str]]
+ :rtype: Union[list[Pet], tuple[list[Pet], int], tuple[list[Pet], int, dict[str, str]]
"""
return 'do some magic!'
@@ -58,9 +56,9 @@ def find_pets_by_tags(tags): # noqa: E501
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
:param tags: Tags to filter by
- :type tags: List[str]
+ :type tags: list[str]
- :rtype: Union[List[Pet], Tuple[List[Pet], int], Tuple[List[Pet], int, Dict[str, str]]
+ :rtype: Union[list[Pet], tuple[list[Pet], int], tuple[list[Pet], int, dict[str, str]]
"""
return 'do some magic!'
@@ -73,7 +71,7 @@ def get_pet_by_id(pet_id): # noqa: E501
:param pet_id: ID of pet to return
:type pet_id: int
- :rtype: Union[Pet, Tuple[Pet, int], Tuple[Pet, int, Dict[str, str]]
+ :rtype: Union[Pet, tuple[Pet, int], tuple[Pet, int, dict[str, str]]
"""
return 'do some magic!'
@@ -86,7 +84,7 @@ def update_pet(body): # noqa: E501
:param pet: Pet object that needs to be added to the store
:type pet: dict | bytes
- :rtype: Union[Pet, Tuple[Pet, int], Tuple[Pet, int, Dict[str, str]]
+ :rtype: Union[Pet, tuple[Pet, int], tuple[Pet, int, dict[str, str]]
"""
pet = body
if connexion.request.is_json:
@@ -106,7 +104,7 @@ def update_pet_with_form(pet_id, name=None, status=None): # noqa: E501
:param status: Updated status of the pet
:type status: str
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
@@ -123,6 +121,6 @@ def upload_file(pet_id, additional_metadata=None, file=None): # noqa: E501
:param file: file to upload
:type file: str
- :rtype: Union[ApiResponse, Tuple[ApiResponse, int], Tuple[ApiResponse, int, Dict[str, str]]
+ :rtype: Union[ApiResponse, tuple[ApiResponse, int], tuple[ApiResponse, int, dict[str, str]]
"""
return 'do some magic!'
diff --git a/samples/server/petstore/python-flask/openapi_server/controllers/security_controller.py b/samples/server/petstore/python-flask/openapi_server/controllers/security_controller.py
index aae1a19e84aa..4e89d2248c90 100644
--- a/samples/server/petstore/python-flask/openapi_server/controllers/security_controller.py
+++ b/samples/server/petstore/python-flask/openapi_server/controllers/security_controller.py
@@ -1,5 +1,3 @@
-from typing import List
-
def info_from_petstore_auth(token):
"""
@@ -21,9 +19,9 @@ def validate_scope_petstore_auth(required_scopes, token_scopes):
Validate required scopes are included in token scope
:param required_scopes Required scope to access called API
- :type required_scopes: List[str]
+ :type required_scopes: list[str]
:param token_scopes Scope present in token
- :type token_scopes: List[str]
+ :type token_scopes: list[str]
:return: True if access to called API is allowed
:rtype: bool
"""
diff --git a/samples/server/petstore/python-flask/openapi_server/controllers/store_controller.py b/samples/server/petstore/python-flask/openapi_server/controllers/store_controller.py
index 27af5fd2513f..2ad8dc029fca 100644
--- a/samples/server/petstore/python-flask/openapi_server/controllers/store_controller.py
+++ b/samples/server/petstore/python-flask/openapi_server/controllers/store_controller.py
@@ -1,6 +1,4 @@
import connexion
-from typing import Dict
-from typing import Tuple
from typing import Union
from openapi_server.models.order import Order # noqa: E501
@@ -15,7 +13,7 @@ def delete_order(order_id): # noqa: E501
:param order_id: ID of the order that needs to be deleted
:type order_id: str
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
@@ -26,7 +24,7 @@ def get_inventory(): # noqa: E501
Returns a map of status codes to quantities # noqa: E501
- :rtype: Union[Dict[str, int], Tuple[Dict[str, int], int], Tuple[Dict[str, int], int, Dict[str, str]]
+ :rtype: Union[dict[str, int], tuple[dict[str, int], int], tuple[dict[str, int], int, dict[str, str]]
"""
return 'do some magic!'
@@ -39,7 +37,7 @@ def get_order_by_id(order_id): # noqa: E501
:param order_id: ID of pet that needs to be fetched
:type order_id: int
- :rtype: Union[Order, Tuple[Order, int], Tuple[Order, int, Dict[str, str]]
+ :rtype: Union[Order, tuple[Order, int], tuple[Order, int, dict[str, str]]
"""
return 'do some magic!'
@@ -52,7 +50,7 @@ def place_order(body): # noqa: E501
:param order: order placed for purchasing the pet
:type order: dict | bytes
- :rtype: Union[Order, Tuple[Order, int], Tuple[Order, int, Dict[str, str]]
+ :rtype: Union[Order, tuple[Order, int], tuple[Order, int, dict[str, str]]
"""
order = body
if connexion.request.is_json:
diff --git a/samples/server/petstore/python-flask/openapi_server/controllers/user_controller.py b/samples/server/petstore/python-flask/openapi_server/controllers/user_controller.py
index 6b318c2cd3e6..7a261b9d547b 100644
--- a/samples/server/petstore/python-flask/openapi_server/controllers/user_controller.py
+++ b/samples/server/petstore/python-flask/openapi_server/controllers/user_controller.py
@@ -1,6 +1,4 @@
import connexion
-from typing import Dict
-from typing import Tuple
from typing import Union
from openapi_server.models.user import User # noqa: E501
@@ -15,7 +13,7 @@ def create_user(body): # noqa: E501
:param user: Created user object
:type user: dict | bytes
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
user = body
if connexion.request.is_json:
@@ -31,7 +29,7 @@ def create_users_with_array_input(body): # noqa: E501
:param user: List of user object
:type user: list | bytes
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
user = body
if connexion.request.is_json:
@@ -47,7 +45,7 @@ def create_users_with_list_input(body): # noqa: E501
:param user: List of user object
:type user: list | bytes
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
user = body
if connexion.request.is_json:
@@ -63,7 +61,7 @@ def delete_user(username): # noqa: E501
:param username: The name that needs to be deleted
:type username: str
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
@@ -76,7 +74,7 @@ def get_user_by_name(username): # noqa: E501
:param username: The name that needs to be fetched. Use user1 for testing.
:type username: str
- :rtype: Union[User, Tuple[User, int], Tuple[User, int, Dict[str, str]]
+ :rtype: Union[User, tuple[User, int], tuple[User, int, dict[str, str]]
"""
return 'do some magic!'
@@ -91,7 +89,7 @@ def login_user(username, password): # noqa: E501
:param password: The password for login in clear text
:type password: str
- :rtype: Union[str, Tuple[str, int], Tuple[str, int, Dict[str, str]]
+ :rtype: Union[str, tuple[str, int], tuple[str, int, dict[str, str]]
"""
return 'do some magic!'
@@ -102,7 +100,7 @@ def logout_user(): # noqa: E501
# noqa: E501
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
return 'do some magic!'
@@ -117,7 +115,7 @@ def update_user(username, body): # noqa: E501
:param user: Updated user object
:type user: dict | bytes
- :rtype: Union[None, Tuple[None, int], Tuple[None, int, Dict[str, str]]
+ :rtype: Union[None, tuple[None, int], tuple[None, int, dict[str, str]]
"""
user = body
if connexion.request.is_json:
diff --git a/samples/server/petstore/python-flask/openapi_server/models/api_response.py b/samples/server/petstore/python-flask/openapi_server/models/api_response.py
index 983e11cc4ea2..1d1a59ce3969 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/api_response.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/api_response.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/base_model.py b/samples/server/petstore/python-flask/openapi_server/models/base_model.py
index c01b423a7432..da7d04c6bc64 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/base_model.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/base_model.py
@@ -10,14 +10,14 @@
class Model:
# openapiTypes: The key is attribute name and the
# value is attribute type.
- openapi_types: typing.Dict[str, type] = {}
+ openapi_types: dict[str, type] = {}
# attributeMap: The key is attribute name and the
# value is json key in definition.
- attribute_map: typing.Dict[str, str] = {}
+ attribute_map: dict[str, str] = {}
@classmethod
- def from_dict(cls: typing.Type[T], dikt) -> T:
+ def from_dict(cls: type[T], dikt) -> T:
"""Returns the dict as a model"""
return util.deserialize_model(dikt, cls)
diff --git a/samples/server/petstore/python-flask/openapi_server/models/category.py b/samples/server/petstore/python-flask/openapi_server/models/category.py
index 9f9805e6f38f..26b9efd85159 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/category.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/category.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
import re
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/order.py b/samples/server/petstore/python-flask/openapi_server/models/order.py
index 1fdf0cb3b798..8f8906a2e354 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/order.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/order.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/pet.py b/samples/server/petstore/python-flask/openapi_server/models/pet.py
index b460a10303ee..4db2aea9c772 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/pet.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/pet.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server.models.category import Category
from openapi_server.models.tag import Tag
@@ -26,9 +24,9 @@ def __init__(self, id=None, category=None, name=None, photo_urls=None, tags=None
:param name: The name of this Pet. # noqa: E501
:type name: str
:param photo_urls: The photo_urls of this Pet. # noqa: E501
- :type photo_urls: List[str]
+ :type photo_urls: list[str]
:param tags: The tags of this Pet. # noqa: E501
- :type tags: List[Tag]
+ :type tags: list[Tag]
:param status: The status of this Pet. # noqa: E501
:type status: str
"""
@@ -36,8 +34,8 @@ def __init__(self, id=None, category=None, name=None, photo_urls=None, tags=None
'id': int,
'category': Category,
'name': str,
- 'photo_urls': List[str],
- 'tags': List[Tag],
+ 'photo_urls': list[str],
+ 'tags': list[Tag],
'status': str
}
@@ -134,22 +132,22 @@ def name(self, name: str):
self._name = name
@property
- def photo_urls(self) -> List[str]:
+ def photo_urls(self) -> list[str]:
"""Gets the photo_urls of this Pet.
:return: The photo_urls of this Pet.
- :rtype: List[str]
+ :rtype: list[str]
"""
return self._photo_urls
@photo_urls.setter
- def photo_urls(self, photo_urls: List[str]):
+ def photo_urls(self, photo_urls: list[str]):
"""Sets the photo_urls of this Pet.
:param photo_urls: The photo_urls of this Pet.
- :type photo_urls: List[str]
+ :type photo_urls: list[str]
"""
if photo_urls is None:
raise ValueError("Invalid value for `photo_urls`, must not be `None`") # noqa: E501
@@ -157,22 +155,22 @@ def photo_urls(self, photo_urls: List[str]):
self._photo_urls = photo_urls
@property
- def tags(self) -> List[Tag]:
+ def tags(self) -> list[Tag]:
"""Gets the tags of this Pet.
:return: The tags of this Pet.
- :rtype: List[Tag]
+ :rtype: list[Tag]
"""
return self._tags
@tags.setter
- def tags(self, tags: List[Tag]):
+ def tags(self, tags: list[Tag]):
"""Sets the tags of this Pet.
:param tags: The tags of this Pet.
- :type tags: List[Tag]
+ :type tags: list[Tag]
"""
self._tags = tags
diff --git a/samples/server/petstore/python-flask/openapi_server/models/tag.py b/samples/server/petstore/python-flask/openapi_server/models/tag.py
index 2a38c9ee02a5..5a8cd5316147 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/tag.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/tag.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/test_enum.py b/samples/server/petstore/python-flask/openapi_server/models/test_enum.py
index d072a34c622c..4ee417968ce7 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/test_enum.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/test_enum.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/test_enum_with_default.py b/samples/server/petstore/python-flask/openapi_server/models/test_enum_with_default.py
index cc715175635f..dcd621498f8c 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/test_enum_with_default.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/test_enum_with_default.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/models/test_model.py b/samples/server/petstore/python-flask/openapi_server/models/test_model.py
index 3550f70389c6..1a2e66fc705b 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/test_model.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/test_model.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server.models.test_enum import TestEnum
from openapi_server.models.test_enum_with_default import TestEnumWithDefault
diff --git a/samples/server/petstore/python-flask/openapi_server/models/user.py b/samples/server/petstore/python-flask/openapi_server/models/user.py
index 868b4c85b941..239f051a6368 100644
--- a/samples/server/petstore/python-flask/openapi_server/models/user.py
+++ b/samples/server/petstore/python-flask/openapi_server/models/user.py
@@ -1,7 +1,5 @@
from datetime import date, datetime # noqa: F401
-from typing import List, Dict # noqa: F401
-
from openapi_server.models.base_model import Model
from openapi_server import util
diff --git a/samples/server/petstore/python-flask/openapi_server/typing_utils.py b/samples/server/petstore/python-flask/openapi_server/typing_utils.py
index 74e3c913a7db..154d655510ba 100644
--- a/samples/server/petstore/python-flask/openapi_server/typing_utils.py
+++ b/samples/server/petstore/python-flask/openapi_server/typing_utils.py
@@ -8,11 +8,11 @@ def is_generic(klass):
return type(klass) == typing.GenericMeta
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__extra__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__extra__ == list
else:
@@ -22,9 +22,9 @@ def is_generic(klass):
return hasattr(klass, '__origin__')
def is_dict(klass):
- """ Determine whether klass is a Dict """
+ """ Determine whether klass is a dict """
return klass.__origin__ == dict
def is_list(klass):
- """ Determine whether klass is a List """
+ """ Determine whether klass is a list """
return klass.__origin__ == list