python-fastapi-rest-server-codegen 1.7.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- python_fastapi_rest_server_codegen-1.7.5/MANIFEST.in +4 -0
- python_fastapi_rest_server_codegen-1.7.5/PKG-INFO +13 -0
- python_fastapi_rest_server_codegen-1.7.5/README.md +70 -0
- python_fastapi_rest_server_codegen-1.7.5/ghost_package/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/ghost_package/codegen.py +81 -0
- python_fastapi_rest_server_codegen-1.7.5/pom.xml +164 -0
- python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/PKG-INFO +13 -0
- python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/SOURCES.txt +206 -0
- python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/dependency_links.txt +1 -0
- python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/requires.txt +5 -0
- python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/top_level.txt +1 -0
- python_fastapi_rest_server_codegen-1.7.5/setup.cfg +7 -0
- python_fastapi_rest_server_codegen-1.7.5/setup.py +63 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/java/fr/lcdp/codegen/PythonRestServerCodegen.java +147 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/META-INF/services/org.openapitools.codegen.CodegenConfig +1 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/api.mustache +82 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/base_api.mustache +33 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/context.mustache +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/endpoint_argument_definition.mustache +1 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/health.mustache +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/model.mustache +14 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/model_generic.mustache +388 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/model_oneof.mustache +67 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/security_api.mustache +166 -0
- python_fastapi_rest_server_codegen-1.7.5/src/main/resources/python-fastapi/python-fastapi-rest-server/token.mustache +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/java/DirectoryUtils.java +149 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/java/PythonRestServerCodegenTest.java +84 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/apis/manage_rfi_api.py +63 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/apis/manage_rfi_api_base.py +18 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/security_api.py +84 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/apiKey/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/apis/search_sale_offer_api.py +78 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/apis/search_sale_offer_api_base.py +29 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/models/sale_offer_status.py +51 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/arrayOfReferencedEnum/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/apis/notification_api.py +61 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/apis/notification_api_base.py +23 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/ad.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/ad_notification_sending.py +105 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/l_order.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/l_order_notification_sending.py +105 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/notification.py +123 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/models/notification_sending.py +101 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/codeWithInheritance/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/apis/search_sale_offer_api.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/apis/search_sale_offer_api_base.py +20 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/models/sale_offer_status.py +51 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/enumPathParam/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/default_api.py +53 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/default_api_base.py +19 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/main.py +25 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/any_identified_mode.py +77 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/any_mode.py +77 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode.py +102 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_a.py +104 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_b.py +104 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_c.py +104 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/multipleOneOfWithDiscriminator/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/apis/auth_api.py +53 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/apis/auth_api_base.py +19 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/models/session.py +104 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/models/user.py +97 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/nullableRef/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/apis/auth_api.py +56 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/apis/auth_api_base.py +21 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/any_authentication_credential.py +78 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/authentication_credential.py +103 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/login_credential.py +107 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/models/refresh_session_credential.py +105 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/oneOfWithDiscriminator/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/apis/search_user_api.py +56 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/apis/search_user_api_base.py +20 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/apis/search_user_feature_api.py +54 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/apis/search_user_feature_api_base.py +18 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/main.py +28 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/orderedTags/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/apis/pets_api.py +96 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/apis/pets_api_base.py +36 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/main.py +25 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/models/error.py +96 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/models/pet.py +98 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/petStore/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_api.py +119 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_api_base.py +43 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_image_api.py +88 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_image_api_base.py +29 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_proscription_api.py +92 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/manage_product_proscription_api_base.py +33 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_api.py +116 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_api_base.py +47 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_image_api.py +88 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_image_api_base.py +30 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_metadata_api.py +84 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_metadata_api_base.py +28 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_proscription_api.py +65 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/apis/search_product_proscription_api_base.py +24 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/main.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/barcodes.py +114 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/http_link.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/image.py +103 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/image_versions.py +105 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/laboratory_link.py +99 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/paginated_object.py +99 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/paginated_product_proscriptions.py +109 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/paginated_products.py +109 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/paging_metadata.py +102 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product.py +272 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_creation_or_update_parameters.py +223 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_dispensation_place.py +46 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_market_status.py +50 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_proscription.py +100 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_proscription_creation_parameters.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_secondary_type.py +97 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_status.py +48 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/product_type.py +97 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/rest_error.py +111 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/statistics.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/update_vidal_package_parameters.py +95 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/vat.py +99 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/models/vidal_package_link.py +97 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/security_api.py +44 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/productApi/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/apis/auth_api.py +79 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/apis/auth_api_base.py +31 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/models/credential.py +97 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/security_api.py +22 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/simpleCode/openapi_server/token.py +38 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/common/health.py +37 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/apis/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/apis/auth_api.py +104 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/apis/auth_api_base.py +35 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/context.py +57 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/main.py +26 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/models/__init__.py +0 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/models/extra_models.py +8 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/security_api.py +44 -0
- python_fastapi_rest_server_codegen-1.7.5/src/test/resources/xRestrict/openapi_server/token.py +38 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: python_fastapi_rest_server_codegen
|
|
3
|
+
Version: 1.7.5
|
|
4
|
+
Summary: Python rest server codegen for Le Comptoir Des Pharmacies
|
|
5
|
+
Home-page: https://bitbucket.org/lecomptoirdespharmacies/lcdp-openapi-codegen
|
|
6
|
+
Author: Le Comptoir Des Pharmacies
|
|
7
|
+
Author-email: g.thrasibule@lecomptoirdespharmacies.fr
|
|
8
|
+
License: Apache-2.0
|
|
9
|
+
Keywords: openapi,python-fastapi-rest-server-codegen,openapi3
|
|
10
|
+
Platform: UNKNOWN
|
|
11
|
+
|
|
12
|
+
Python rest server codegen for Le Comptoir Des Pharmacies
|
|
13
|
+
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# OpenAPI Generator for the python-fastapi-rest-server-codegen library
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
This is a boiler-plate project to generate your own project derived from an OpenAPI specification.
|
|
5
|
+
|
|
6
|
+
## What's OpenAPI
|
|
7
|
+
The goal of OpenAPI is to define a standard, language-agnostic interface to REST APIs which allows both humans and computers to discover and understand the capabilities of the service without access to source code, documentation, or through network traffic inspection.
|
|
8
|
+
When properly described with OpenAPI, a consumer can understand and interact with the remote service with a minimal amount of implementation logic.
|
|
9
|
+
Similar to what interfaces have done for lower-level programming, OpenAPI removes the guesswork in calling the service.
|
|
10
|
+
|
|
11
|
+
Check out [OpenAPI-Spec](https://github.com/OAI/OpenAPI-Specification) for additional information about the OpenAPI project, including additional libraries with support for other languages and more.
|
|
12
|
+
|
|
13
|
+
## How do I use this?
|
|
14
|
+
At this point, you've likely generated a server setup. It will include something along these lines:
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
.
|
|
18
|
+
|- README.md // this file
|
|
19
|
+
|- pom.xml // build script
|
|
20
|
+
|-- src
|
|
21
|
+
|--- main
|
|
22
|
+
|---- java
|
|
23
|
+
|----- fr.lcdp.codegen.PythonRestServerCodegen.java // generator file
|
|
24
|
+
|---- resources
|
|
25
|
+
|----- python.lcdp // template files
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
Templates in this folder:
|
|
30
|
+
|
|
31
|
+
`src/main/resources/python/lcdp`
|
|
32
|
+
|
|
33
|
+
Once modified, you can run this:
|
|
34
|
+
|
|
35
|
+
```
|
|
36
|
+
mvn package
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
In your generator project. A single jar file will be produced in `target`. You can now use that with [OpenAPI Generator](https://openapi-generator.tech):
|
|
40
|
+
|
|
41
|
+
For mac/linux:
|
|
42
|
+
```
|
|
43
|
+
java -cp /path/to/openapi-generator-cli.jar:/path/to/your.jar org.openapitools.codegen.OpenAPIGenerator generate -g python-rest-client-codegen -i /path/to/openapi.yaml -o ./test
|
|
44
|
+
```
|
|
45
|
+
(Do not forget to replace the values `/path/to/openapi-generator-cli.jar`, `/path/to/your.jar` and `/path/to/openapi.yaml` in the previous command)
|
|
46
|
+
|
|
47
|
+
For Windows users, you will need to use `;` instead of `:` in the classpath, e.g.
|
|
48
|
+
```
|
|
49
|
+
java -cp /path/to/openapi-generator-cli.jar;/path/to/your.jar org.openapitools.codegen.OpenAPIGenerator generate -g python-rest-client-codegen -i /path/to/openapi.yaml -o ./test
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Now your templates are available to the server generator and you can write output values
|
|
53
|
+
|
|
54
|
+
## Debugging
|
|
55
|
+
|
|
56
|
+
You can execute the `java` command from above while passing different debug flags to show
|
|
57
|
+
the object you have available during server generation:
|
|
58
|
+
|
|
59
|
+
```
|
|
60
|
+
# The following additional debug options are available for all codegen targets:
|
|
61
|
+
# -DdebugOpenAPI prints the OpenAPI Specification as interpreted by the codegen
|
|
62
|
+
# -DdebugModels prints models passed to the template engine
|
|
63
|
+
# -DdebugOperations prints operations passed to the template engine
|
|
64
|
+
# -DdebugSupportingFiles prints additional data passed to the template engine
|
|
65
|
+
|
|
66
|
+
java -DdebugOperations -cp /path/to/openapi-generator-cli.jar:/path/to/your.jar org.openapitools.codegen.OpenAPIGenerator generate -g python-rest-client-codegen -i /path/to/openapi.yaml -o ./test
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Will, for example, output the debug info for operations.
|
|
70
|
+
You can use this info in the `api.mustache` file.
|
|
File without changes
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import subprocess
|
|
2
|
+
import os
|
|
3
|
+
import lcdp_api.rest
|
|
4
|
+
from pathlib import Path
|
|
5
|
+
|
|
6
|
+
try:
|
|
7
|
+
import importlib.resources as pkg_resources
|
|
8
|
+
except ImportError:
|
|
9
|
+
# Try backported to PY<37 `importlib_resources`.
|
|
10
|
+
import importlib_resources as pkg_resources
|
|
11
|
+
|
|
12
|
+
# Get current script dir
|
|
13
|
+
CURRENT_DIR = os.path.dirname(os.path.realpath(__file__))
|
|
14
|
+
|
|
15
|
+
# Codegen command constants
|
|
16
|
+
OPENAPI_CODEGEN_CLASS = "org.openapitools.codegen.OpenAPIGenerator"
|
|
17
|
+
|
|
18
|
+
def get_api_path(api_filename):
|
|
19
|
+
return pkg_resources.path(lcdp_api.rest, api_filename)
|
|
20
|
+
|
|
21
|
+
def get_codegen_cli_path():
|
|
22
|
+
return pkg_resources.path(__package__, "openapi-generator-cli.jar")
|
|
23
|
+
|
|
24
|
+
def get_codegen_path():
|
|
25
|
+
return pkg_resources.path(__package__, "python-fastapi-rest-server-codegen.jar")
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
def generate_provider(api_spec_file_name, out_dir):
|
|
29
|
+
with get_api_path(api_spec_file_name) as api_spec_file_path:
|
|
30
|
+
api_name = get_api_name_from_spec_file_path(api_spec_file_path)
|
|
31
|
+
|
|
32
|
+
api_spec_file_abs_path = os.path.join(CURRENT_DIR, "..", api_spec_file_path)
|
|
33
|
+
|
|
34
|
+
# Compute generator path
|
|
35
|
+
with get_codegen_path() as server_codegen_jar_path, get_codegen_cli_path() as cli_jar_path:
|
|
36
|
+
openapi_codegen_java_classpath = compute_codegen_java_classpath(cli_jar_path, server_codegen_jar_path)
|
|
37
|
+
|
|
38
|
+
execute_provider_codegen(openapi_codegen_java_classpath, server_codegen_jar_path.stem, api_spec_file_abs_path,
|
|
39
|
+
out_dir, "api.provide.gen", "api.provide.impl", api_name)
|
|
40
|
+
|
|
41
|
+
def get_api_name_from_spec_file_path(api_spec_file_path):
|
|
42
|
+
api_name = os.path.basename(api_spec_file_path).split(".")[0]
|
|
43
|
+
return api_name.replace("-", "_")
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def compute_codegen_java_classpath(cli_jar_path, codegen_jar_path):
|
|
47
|
+
sep = ";" if os.name == "nt" else ":"
|
|
48
|
+
return sep.join([str(cli_jar_path), str(codegen_jar_path)])
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
def execute_provider_codegen(openapi_codegen_java_classpath, codegen_name,
|
|
52
|
+
api_spec_file_path, outdir,
|
|
53
|
+
package_name, package_name_impl, api_name):
|
|
54
|
+
"""
|
|
55
|
+
Provider is generated above leaf
|
|
56
|
+
"""
|
|
57
|
+
properties = [
|
|
58
|
+
"--package-name", package_name + "." + api_name
|
|
59
|
+
]
|
|
60
|
+
|
|
61
|
+
additional_properties = [
|
|
62
|
+
"controllerPackage=" + api_name + '.controllers',
|
|
63
|
+
"packageNameImpl=" + package_name_impl + "." + api_name + ".controllers",
|
|
64
|
+
"testPackage=" + api_name + '.tests',
|
|
65
|
+
"apiDocPath=" + api_name + '/docs',
|
|
66
|
+
"modelDocPath=" + api_name + '/docs',
|
|
67
|
+
"fastapiImplementationPackage=" + package_name_impl + "." + api_name + ".controllers",
|
|
68
|
+
"commonPackageName=" + package_name + ".common",
|
|
69
|
+
]
|
|
70
|
+
|
|
71
|
+
execute_codegen_command(openapi_codegen_java_classpath, codegen_name, api_spec_file_path, outdir, properties,
|
|
72
|
+
additional_properties)
|
|
73
|
+
|
|
74
|
+
def execute_codegen_command(openapi_codegen_java_classpath, codegen_name, api_spec_file_path, outdir, properties,
|
|
75
|
+
additional_properties):
|
|
76
|
+
subprocess.check_call(["java", "-cp", openapi_codegen_java_classpath, OPENAPI_CODEGEN_CLASS, "generate", "-g",
|
|
77
|
+
codegen_name, "-i", api_spec_file_path, "-o", outdir] +
|
|
78
|
+
properties +
|
|
79
|
+
# controllerPackage is used by server codegen
|
|
80
|
+
["--additional-properties=" + ",".join(additional_properties)
|
|
81
|
+
])
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
2
|
+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
3
|
+
<modelVersion>4.0.0</modelVersion>
|
|
4
|
+
<groupId>fr.lcdp</groupId>
|
|
5
|
+
<artifactId>python-fastapi-rest-server-codegen</artifactId>
|
|
6
|
+
<packaging>jar</packaging>
|
|
7
|
+
<version>0</version>
|
|
8
|
+
|
|
9
|
+
<properties>
|
|
10
|
+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
11
|
+
<maven.compiler.source>8</maven.compiler.source>
|
|
12
|
+
<maven.compiler.target>8</maven.compiler.target>
|
|
13
|
+
<maven.compiler.version>3.8.1</maven.compiler.version>
|
|
14
|
+
<openapi-generator-version>7.8.0</openapi-generator-version>
|
|
15
|
+
</properties>
|
|
16
|
+
|
|
17
|
+
<build>
|
|
18
|
+
<finalName>python-fastapi-rest-server-codegen</finalName>
|
|
19
|
+
<plugins>
|
|
20
|
+
<plugin>
|
|
21
|
+
<groupId>org.apache.maven.plugins</groupId>
|
|
22
|
+
<artifactId>maven-enforcer-plugin</artifactId>
|
|
23
|
+
<version>3.0.0-M1</version>
|
|
24
|
+
<executions>
|
|
25
|
+
<execution>
|
|
26
|
+
<id>enforce-maven</id>
|
|
27
|
+
<goals>
|
|
28
|
+
<goal>enforce</goal>
|
|
29
|
+
</goals>
|
|
30
|
+
<configuration>
|
|
31
|
+
<rules>
|
|
32
|
+
<requireMavenVersion>
|
|
33
|
+
<version>2.2.0</version>
|
|
34
|
+
</requireMavenVersion>
|
|
35
|
+
</rules>
|
|
36
|
+
</configuration>
|
|
37
|
+
</execution>
|
|
38
|
+
</executions>
|
|
39
|
+
</plugin>
|
|
40
|
+
<plugin>
|
|
41
|
+
<groupId>org.apache.maven.plugins</groupId>
|
|
42
|
+
<artifactId>maven-surefire-plugin</artifactId>
|
|
43
|
+
<version>2.12</version>
|
|
44
|
+
<configuration>
|
|
45
|
+
<systemProperties>
|
|
46
|
+
<property>
|
|
47
|
+
<name>loggerPath</name>
|
|
48
|
+
<value>conf/log4j.properties</value>
|
|
49
|
+
</property>
|
|
50
|
+
</systemProperties>
|
|
51
|
+
<argLine>-Xms512m -Xmx1500m</argLine>
|
|
52
|
+
<parallel>methods</parallel>
|
|
53
|
+
<forkMode>pertest</forkMode>
|
|
54
|
+
</configuration>
|
|
55
|
+
</plugin>
|
|
56
|
+
|
|
57
|
+
<!-- attach test jar -->
|
|
58
|
+
<plugin>
|
|
59
|
+
<groupId>org.apache.maven.plugins</groupId>
|
|
60
|
+
<artifactId>maven-jar-plugin</artifactId>
|
|
61
|
+
<version>2.2</version>
|
|
62
|
+
<executions>
|
|
63
|
+
<execution>
|
|
64
|
+
<goals>
|
|
65
|
+
<goal>jar</goal>
|
|
66
|
+
<goal>test-jar</goal>
|
|
67
|
+
</goals>
|
|
68
|
+
</execution>
|
|
69
|
+
</executions>
|
|
70
|
+
<configuration>
|
|
71
|
+
</configuration>
|
|
72
|
+
</plugin>
|
|
73
|
+
|
|
74
|
+
<plugin>
|
|
75
|
+
<groupId>org.codehaus.mojo</groupId>
|
|
76
|
+
<artifactId>build-helper-maven-plugin</artifactId>
|
|
77
|
+
<version>3.0.0</version>
|
|
78
|
+
<executions>
|
|
79
|
+
<execution>
|
|
80
|
+
<id>add_sources</id>
|
|
81
|
+
<phase>generate-sources</phase>
|
|
82
|
+
<goals>
|
|
83
|
+
<goal>add-source</goal>
|
|
84
|
+
</goals>
|
|
85
|
+
<configuration>
|
|
86
|
+
<sources>
|
|
87
|
+
<source>
|
|
88
|
+
src/main/java</source>
|
|
89
|
+
</sources>
|
|
90
|
+
</configuration>
|
|
91
|
+
</execution>
|
|
92
|
+
<execution>
|
|
93
|
+
<id>add_test_sources</id>
|
|
94
|
+
<phase>generate-test-sources</phase>
|
|
95
|
+
<goals>
|
|
96
|
+
<goal>add-test-source</goal>
|
|
97
|
+
</goals>
|
|
98
|
+
<configuration>
|
|
99
|
+
<sources>
|
|
100
|
+
<source>
|
|
101
|
+
src/test/java</source>
|
|
102
|
+
</sources>
|
|
103
|
+
</configuration>
|
|
104
|
+
</execution>
|
|
105
|
+
</executions>
|
|
106
|
+
</plugin>
|
|
107
|
+
<plugin>
|
|
108
|
+
<groupId>org.apache.maven.plugins</groupId>
|
|
109
|
+
<artifactId>maven-compiler-plugin</artifactId>
|
|
110
|
+
<version>${maven.compiler.version}</version>
|
|
111
|
+
</plugin>
|
|
112
|
+
</plugins>
|
|
113
|
+
|
|
114
|
+
<extensions>
|
|
115
|
+
<extension>
|
|
116
|
+
<groupId>ar.com.synergian</groupId>
|
|
117
|
+
<artifactId>wagon-git</artifactId>
|
|
118
|
+
<version>0.2.5</version>
|
|
119
|
+
</extension>
|
|
120
|
+
</extensions>
|
|
121
|
+
</build>
|
|
122
|
+
<dependencies>
|
|
123
|
+
<dependency>
|
|
124
|
+
<groupId>org.openapitools</groupId>
|
|
125
|
+
<artifactId>openapi-generator</artifactId>
|
|
126
|
+
<version>${openapi-generator-version}</version>
|
|
127
|
+
<scope>provided</scope>
|
|
128
|
+
</dependency>
|
|
129
|
+
<dependency>
|
|
130
|
+
<groupId>org.openapitools</groupId>
|
|
131
|
+
<artifactId>openapi-generator</artifactId>
|
|
132
|
+
<version>${openapi-generator-version}</version>
|
|
133
|
+
<type>test-jar</type>
|
|
134
|
+
<scope>test</scope>
|
|
135
|
+
</dependency>
|
|
136
|
+
<dependency>
|
|
137
|
+
<groupId>junit</groupId>
|
|
138
|
+
<artifactId>junit</artifactId>
|
|
139
|
+
<version>4.11</version>
|
|
140
|
+
<scope>test</scope>
|
|
141
|
+
</dependency>
|
|
142
|
+
</dependencies>
|
|
143
|
+
|
|
144
|
+
<!-- Delivery -->
|
|
145
|
+
<pluginRepositories>
|
|
146
|
+
<pluginRepository>
|
|
147
|
+
<id>synergian-repo</id>
|
|
148
|
+
<url>https://raw.github.com/synergian/wagon-git/releases</url>
|
|
149
|
+
</pluginRepository>
|
|
150
|
+
</pluginRepositories>
|
|
151
|
+
|
|
152
|
+
<distributionManagement>
|
|
153
|
+
<repository>
|
|
154
|
+
<id>lecomptoirdespharmacies.repo</id>
|
|
155
|
+
<name>Le Comptoir Des Pharmacies Repository</name>
|
|
156
|
+
<url>git:releases://git@bitbucket.org:lecomptoirdespharmacies/maven_repository.git</url>
|
|
157
|
+
</repository>
|
|
158
|
+
<snapshotRepository>
|
|
159
|
+
<id>lecomptoirdespharmacies.repo</id>
|
|
160
|
+
<name>Le Comptoir Des Pharmacies Repository</name>
|
|
161
|
+
<url>git:snapshots://git@bitbucket.org:lecomptoirdespharmacies/maven_repository.git</url>
|
|
162
|
+
</snapshotRepository>
|
|
163
|
+
</distributionManagement>
|
|
164
|
+
</project>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: python-fastapi-rest-server-codegen
|
|
3
|
+
Version: 1.7.5
|
|
4
|
+
Summary: Python rest server codegen for Le Comptoir Des Pharmacies
|
|
5
|
+
Home-page: https://bitbucket.org/lecomptoirdespharmacies/lcdp-openapi-codegen
|
|
6
|
+
Author: Le Comptoir Des Pharmacies
|
|
7
|
+
Author-email: g.thrasibule@lecomptoirdespharmacies.fr
|
|
8
|
+
License: Apache-2.0
|
|
9
|
+
Keywords: openapi,python-fastapi-rest-server-codegen,openapi3
|
|
10
|
+
Platform: UNKNOWN
|
|
11
|
+
|
|
12
|
+
Python rest server codegen for Le Comptoir Des Pharmacies
|
|
13
|
+
|
python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/SOURCES.txt
ADDED
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
MANIFEST.in
|
|
2
|
+
README.md
|
|
3
|
+
pom.xml
|
|
4
|
+
setup.cfg
|
|
5
|
+
setup.py
|
|
6
|
+
ghost_package/__init__.py
|
|
7
|
+
ghost_package/codegen.py
|
|
8
|
+
python_fastapi_rest_server_codegen.egg-info/PKG-INFO
|
|
9
|
+
python_fastapi_rest_server_codegen.egg-info/SOURCES.txt
|
|
10
|
+
python_fastapi_rest_server_codegen.egg-info/dependency_links.txt
|
|
11
|
+
python_fastapi_rest_server_codegen.egg-info/requires.txt
|
|
12
|
+
python_fastapi_rest_server_codegen.egg-info/top_level.txt
|
|
13
|
+
src/main/java/fr/lcdp/codegen/PythonRestServerCodegen.java
|
|
14
|
+
src/main/resources/META-INF/services/org.openapitools.codegen.CodegenConfig
|
|
15
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/api.mustache
|
|
16
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/base_api.mustache
|
|
17
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/context.mustache
|
|
18
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/endpoint_argument_definition.mustache
|
|
19
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/health.mustache
|
|
20
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/model.mustache
|
|
21
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/model_generic.mustache
|
|
22
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/model_oneof.mustache
|
|
23
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/security_api.mustache
|
|
24
|
+
src/main/resources/python-fastapi/python-fastapi-rest-server/token.mustache
|
|
25
|
+
src/test/java/DirectoryUtils.java
|
|
26
|
+
src/test/java/PythonRestServerCodegenTest.java
|
|
27
|
+
src/test/resources/apiKey/common/health.py
|
|
28
|
+
src/test/resources/apiKey/openapi_server/context.py
|
|
29
|
+
src/test/resources/apiKey/openapi_server/main.py
|
|
30
|
+
src/test/resources/apiKey/openapi_server/security_api.py
|
|
31
|
+
src/test/resources/apiKey/openapi_server/token.py
|
|
32
|
+
src/test/resources/apiKey/openapi_server/apis/__init__.py
|
|
33
|
+
src/test/resources/apiKey/openapi_server/apis/manage_rfi_api.py
|
|
34
|
+
src/test/resources/apiKey/openapi_server/apis/manage_rfi_api_base.py
|
|
35
|
+
src/test/resources/apiKey/openapi_server/models/__init__.py
|
|
36
|
+
src/test/resources/apiKey/openapi_server/models/extra_models.py
|
|
37
|
+
src/test/resources/arrayOfReferencedEnum/common/health.py
|
|
38
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/context.py
|
|
39
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/main.py
|
|
40
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/security_api.py
|
|
41
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/token.py
|
|
42
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/apis/__init__.py
|
|
43
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/apis/search_sale_offer_api.py
|
|
44
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/apis/search_sale_offer_api_base.py
|
|
45
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/models/__init__.py
|
|
46
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/models/extra_models.py
|
|
47
|
+
src/test/resources/arrayOfReferencedEnum/openapi_server/models/sale_offer_status.py
|
|
48
|
+
src/test/resources/codeWithInheritance/common/health.py
|
|
49
|
+
src/test/resources/codeWithInheritance/openapi_server/context.py
|
|
50
|
+
src/test/resources/codeWithInheritance/openapi_server/main.py
|
|
51
|
+
src/test/resources/codeWithInheritance/openapi_server/security_api.py
|
|
52
|
+
src/test/resources/codeWithInheritance/openapi_server/token.py
|
|
53
|
+
src/test/resources/codeWithInheritance/openapi_server/apis/__init__.py
|
|
54
|
+
src/test/resources/codeWithInheritance/openapi_server/apis/notification_api.py
|
|
55
|
+
src/test/resources/codeWithInheritance/openapi_server/apis/notification_api_base.py
|
|
56
|
+
src/test/resources/codeWithInheritance/openapi_server/models/__init__.py
|
|
57
|
+
src/test/resources/codeWithInheritance/openapi_server/models/ad.py
|
|
58
|
+
src/test/resources/codeWithInheritance/openapi_server/models/ad_notification_sending.py
|
|
59
|
+
src/test/resources/codeWithInheritance/openapi_server/models/extra_models.py
|
|
60
|
+
src/test/resources/codeWithInheritance/openapi_server/models/l_order.py
|
|
61
|
+
src/test/resources/codeWithInheritance/openapi_server/models/l_order_notification_sending.py
|
|
62
|
+
src/test/resources/codeWithInheritance/openapi_server/models/notification.py
|
|
63
|
+
src/test/resources/codeWithInheritance/openapi_server/models/notification_sending.py
|
|
64
|
+
src/test/resources/enumPathParam/common/health.py
|
|
65
|
+
src/test/resources/enumPathParam/openapi_server/context.py
|
|
66
|
+
src/test/resources/enumPathParam/openapi_server/main.py
|
|
67
|
+
src/test/resources/enumPathParam/openapi_server/security_api.py
|
|
68
|
+
src/test/resources/enumPathParam/openapi_server/token.py
|
|
69
|
+
src/test/resources/enumPathParam/openapi_server/apis/__init__.py
|
|
70
|
+
src/test/resources/enumPathParam/openapi_server/apis/search_sale_offer_api.py
|
|
71
|
+
src/test/resources/enumPathParam/openapi_server/apis/search_sale_offer_api_base.py
|
|
72
|
+
src/test/resources/enumPathParam/openapi_server/models/__init__.py
|
|
73
|
+
src/test/resources/enumPathParam/openapi_server/models/extra_models.py
|
|
74
|
+
src/test/resources/enumPathParam/openapi_server/models/sale_offer_status.py
|
|
75
|
+
src/test/resources/multipleOneOfWithDiscriminator/common/health.py
|
|
76
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/context.py
|
|
77
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/main.py
|
|
78
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/security_api.py
|
|
79
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/token.py
|
|
80
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/__init__.py
|
|
81
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/default_api.py
|
|
82
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/apis/default_api_base.py
|
|
83
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/__init__.py
|
|
84
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/any_identified_mode.py
|
|
85
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/any_mode.py
|
|
86
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/extra_models.py
|
|
87
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode.py
|
|
88
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_a.py
|
|
89
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_b.py
|
|
90
|
+
src/test/resources/multipleOneOfWithDiscriminator/openapi_server/models/mode_c.py
|
|
91
|
+
src/test/resources/nullableRef/common/health.py
|
|
92
|
+
src/test/resources/nullableRef/openapi_server/context.py
|
|
93
|
+
src/test/resources/nullableRef/openapi_server/main.py
|
|
94
|
+
src/test/resources/nullableRef/openapi_server/security_api.py
|
|
95
|
+
src/test/resources/nullableRef/openapi_server/token.py
|
|
96
|
+
src/test/resources/nullableRef/openapi_server/apis/__init__.py
|
|
97
|
+
src/test/resources/nullableRef/openapi_server/apis/auth_api.py
|
|
98
|
+
src/test/resources/nullableRef/openapi_server/apis/auth_api_base.py
|
|
99
|
+
src/test/resources/nullableRef/openapi_server/models/__init__.py
|
|
100
|
+
src/test/resources/nullableRef/openapi_server/models/extra_models.py
|
|
101
|
+
src/test/resources/nullableRef/openapi_server/models/session.py
|
|
102
|
+
src/test/resources/nullableRef/openapi_server/models/user.py
|
|
103
|
+
src/test/resources/oneOfWithDiscriminator/common/health.py
|
|
104
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/context.py
|
|
105
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/main.py
|
|
106
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/security_api.py
|
|
107
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/token.py
|
|
108
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/apis/__init__.py
|
|
109
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/apis/auth_api.py
|
|
110
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/apis/auth_api_base.py
|
|
111
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/__init__.py
|
|
112
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/any_authentication_credential.py
|
|
113
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/authentication_credential.py
|
|
114
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/extra_models.py
|
|
115
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/login_credential.py
|
|
116
|
+
src/test/resources/oneOfWithDiscriminator/openapi_server/models/refresh_session_credential.py
|
|
117
|
+
src/test/resources/orderedTags/common/health.py
|
|
118
|
+
src/test/resources/orderedTags/openapi_server/context.py
|
|
119
|
+
src/test/resources/orderedTags/openapi_server/main.py
|
|
120
|
+
src/test/resources/orderedTags/openapi_server/security_api.py
|
|
121
|
+
src/test/resources/orderedTags/openapi_server/token.py
|
|
122
|
+
src/test/resources/orderedTags/openapi_server/apis/__init__.py
|
|
123
|
+
src/test/resources/orderedTags/openapi_server/apis/search_user_api.py
|
|
124
|
+
src/test/resources/orderedTags/openapi_server/apis/search_user_api_base.py
|
|
125
|
+
src/test/resources/orderedTags/openapi_server/apis/search_user_feature_api.py
|
|
126
|
+
src/test/resources/orderedTags/openapi_server/apis/search_user_feature_api_base.py
|
|
127
|
+
src/test/resources/orderedTags/openapi_server/models/__init__.py
|
|
128
|
+
src/test/resources/orderedTags/openapi_server/models/extra_models.py
|
|
129
|
+
src/test/resources/petStore/common/health.py
|
|
130
|
+
src/test/resources/petStore/openapi_server/context.py
|
|
131
|
+
src/test/resources/petStore/openapi_server/main.py
|
|
132
|
+
src/test/resources/petStore/openapi_server/security_api.py
|
|
133
|
+
src/test/resources/petStore/openapi_server/token.py
|
|
134
|
+
src/test/resources/petStore/openapi_server/apis/__init__.py
|
|
135
|
+
src/test/resources/petStore/openapi_server/apis/pets_api.py
|
|
136
|
+
src/test/resources/petStore/openapi_server/apis/pets_api_base.py
|
|
137
|
+
src/test/resources/petStore/openapi_server/models/__init__.py
|
|
138
|
+
src/test/resources/petStore/openapi_server/models/error.py
|
|
139
|
+
src/test/resources/petStore/openapi_server/models/extra_models.py
|
|
140
|
+
src/test/resources/petStore/openapi_server/models/pet.py
|
|
141
|
+
src/test/resources/productApi/common/health.py
|
|
142
|
+
src/test/resources/productApi/openapi_server/context.py
|
|
143
|
+
src/test/resources/productApi/openapi_server/main.py
|
|
144
|
+
src/test/resources/productApi/openapi_server/security_api.py
|
|
145
|
+
src/test/resources/productApi/openapi_server/token.py
|
|
146
|
+
src/test/resources/productApi/openapi_server/apis/__init__.py
|
|
147
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_api.py
|
|
148
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_api_base.py
|
|
149
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_image_api.py
|
|
150
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_image_api_base.py
|
|
151
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_proscription_api.py
|
|
152
|
+
src/test/resources/productApi/openapi_server/apis/manage_product_proscription_api_base.py
|
|
153
|
+
src/test/resources/productApi/openapi_server/apis/search_product_api.py
|
|
154
|
+
src/test/resources/productApi/openapi_server/apis/search_product_api_base.py
|
|
155
|
+
src/test/resources/productApi/openapi_server/apis/search_product_image_api.py
|
|
156
|
+
src/test/resources/productApi/openapi_server/apis/search_product_image_api_base.py
|
|
157
|
+
src/test/resources/productApi/openapi_server/apis/search_product_metadata_api.py
|
|
158
|
+
src/test/resources/productApi/openapi_server/apis/search_product_metadata_api_base.py
|
|
159
|
+
src/test/resources/productApi/openapi_server/apis/search_product_proscription_api.py
|
|
160
|
+
src/test/resources/productApi/openapi_server/apis/search_product_proscription_api_base.py
|
|
161
|
+
src/test/resources/productApi/openapi_server/models/__init__.py
|
|
162
|
+
src/test/resources/productApi/openapi_server/models/barcodes.py
|
|
163
|
+
src/test/resources/productApi/openapi_server/models/extra_models.py
|
|
164
|
+
src/test/resources/productApi/openapi_server/models/http_link.py
|
|
165
|
+
src/test/resources/productApi/openapi_server/models/image.py
|
|
166
|
+
src/test/resources/productApi/openapi_server/models/image_versions.py
|
|
167
|
+
src/test/resources/productApi/openapi_server/models/laboratory_link.py
|
|
168
|
+
src/test/resources/productApi/openapi_server/models/paginated_object.py
|
|
169
|
+
src/test/resources/productApi/openapi_server/models/paginated_product_proscriptions.py
|
|
170
|
+
src/test/resources/productApi/openapi_server/models/paginated_products.py
|
|
171
|
+
src/test/resources/productApi/openapi_server/models/paging_metadata.py
|
|
172
|
+
src/test/resources/productApi/openapi_server/models/product.py
|
|
173
|
+
src/test/resources/productApi/openapi_server/models/product_creation_or_update_parameters.py
|
|
174
|
+
src/test/resources/productApi/openapi_server/models/product_dispensation_place.py
|
|
175
|
+
src/test/resources/productApi/openapi_server/models/product_market_status.py
|
|
176
|
+
src/test/resources/productApi/openapi_server/models/product_proscription.py
|
|
177
|
+
src/test/resources/productApi/openapi_server/models/product_proscription_creation_parameters.py
|
|
178
|
+
src/test/resources/productApi/openapi_server/models/product_secondary_type.py
|
|
179
|
+
src/test/resources/productApi/openapi_server/models/product_status.py
|
|
180
|
+
src/test/resources/productApi/openapi_server/models/product_type.py
|
|
181
|
+
src/test/resources/productApi/openapi_server/models/rest_error.py
|
|
182
|
+
src/test/resources/productApi/openapi_server/models/statistics.py
|
|
183
|
+
src/test/resources/productApi/openapi_server/models/update_vidal_package_parameters.py
|
|
184
|
+
src/test/resources/productApi/openapi_server/models/vat.py
|
|
185
|
+
src/test/resources/productApi/openapi_server/models/vidal_package_link.py
|
|
186
|
+
src/test/resources/simpleCode/common/health.py
|
|
187
|
+
src/test/resources/simpleCode/openapi_server/context.py
|
|
188
|
+
src/test/resources/simpleCode/openapi_server/main.py
|
|
189
|
+
src/test/resources/simpleCode/openapi_server/security_api.py
|
|
190
|
+
src/test/resources/simpleCode/openapi_server/token.py
|
|
191
|
+
src/test/resources/simpleCode/openapi_server/apis/__init__.py
|
|
192
|
+
src/test/resources/simpleCode/openapi_server/apis/auth_api.py
|
|
193
|
+
src/test/resources/simpleCode/openapi_server/apis/auth_api_base.py
|
|
194
|
+
src/test/resources/simpleCode/openapi_server/models/__init__.py
|
|
195
|
+
src/test/resources/simpleCode/openapi_server/models/credential.py
|
|
196
|
+
src/test/resources/simpleCode/openapi_server/models/extra_models.py
|
|
197
|
+
src/test/resources/xRestrict/common/health.py
|
|
198
|
+
src/test/resources/xRestrict/openapi_server/context.py
|
|
199
|
+
src/test/resources/xRestrict/openapi_server/main.py
|
|
200
|
+
src/test/resources/xRestrict/openapi_server/security_api.py
|
|
201
|
+
src/test/resources/xRestrict/openapi_server/token.py
|
|
202
|
+
src/test/resources/xRestrict/openapi_server/apis/__init__.py
|
|
203
|
+
src/test/resources/xRestrict/openapi_server/apis/auth_api.py
|
|
204
|
+
src/test/resources/xRestrict/openapi_server/apis/auth_api_base.py
|
|
205
|
+
src/test/resources/xRestrict/openapi_server/models/__init__.py
|
|
206
|
+
src/test/resources/xRestrict/openapi_server/models/extra_models.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
python_fastapi_rest_server_codegen-1.7.5/python_fastapi_rest_server_codegen.egg-info/top_level.txt
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
python_fastapi_rest_server_codegen
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import subprocess
|
|
2
|
+
import glob
|
|
3
|
+
import shutil
|
|
4
|
+
import os
|
|
5
|
+
from setuptools import setup
|
|
6
|
+
from setuptools.command.build_py import build_py
|
|
7
|
+
|
|
8
|
+
try:
|
|
9
|
+
import importlib.resources as pkg_resources
|
|
10
|
+
except ImportError:
|
|
11
|
+
# Try backported to PY<37 `importlib_resources`.
|
|
12
|
+
import importlib_resources as pkg_resources
|
|
13
|
+
|
|
14
|
+
TOP_LEVEL_PACKAGE_NAME = "python_fastapi_rest_server_codegen"
|
|
15
|
+
|
|
16
|
+
class CustomBuild(build_py):
|
|
17
|
+
def run(self):
|
|
18
|
+
# Build target jar
|
|
19
|
+
subprocess.check_call(["mvn", "clean", "package"])
|
|
20
|
+
|
|
21
|
+
# Run classic build that will convert ghost_package to toplevel
|
|
22
|
+
build_py.run(self)
|
|
23
|
+
|
|
24
|
+
# Find toplevel and add files in it
|
|
25
|
+
toplevel_package = os.path.join(self.build_lib, TOP_LEVEL_PACKAGE_NAME)
|
|
26
|
+
for file in glob.glob("target/*.jar"):
|
|
27
|
+
shutil.copy(file, toplevel_package)
|
|
28
|
+
|
|
29
|
+
import openapi_generator_cli
|
|
30
|
+
with pkg_resources.path(openapi_generator_cli, "openapi-generator-cli.jar") as openapi_generator_cli_jar:
|
|
31
|
+
shutil.copy(str(openapi_generator_cli_jar), toplevel_package)
|
|
32
|
+
|
|
33
|
+
setup(
|
|
34
|
+
name="python_fastapi_rest_server_codegen",
|
|
35
|
+
version_config={
|
|
36
|
+
"dirty_template": "{tag}.post{ccount}+git.{sha}", # See : https://github.com/dolfinus/setuptools-git-versioning/pull/16#issuecomment-867444549
|
|
37
|
+
},
|
|
38
|
+
install_requires=[
|
|
39
|
+
'connexion==3.1.0',
|
|
40
|
+
'python_dateutil >= 2.6.0',
|
|
41
|
+
'Flask == 2.2.5',
|
|
42
|
+
'Werkzeug == 2.2.2',
|
|
43
|
+
'pyjwt==2.8.0',
|
|
44
|
+
],
|
|
45
|
+
setup_requires=[
|
|
46
|
+
'setuptools-git-versioning==1.4.0',
|
|
47
|
+
'python-openapi-generator-cli-jar==7.8.0'
|
|
48
|
+
],
|
|
49
|
+
packages=[TOP_LEVEL_PACKAGE_NAME],
|
|
50
|
+
package_data={
|
|
51
|
+
# If any package contains *.jar files, include them:
|
|
52
|
+
TOP_LEVEL_PACKAGE_NAME: ['*.jar'],
|
|
53
|
+
},
|
|
54
|
+
package_dir={TOP_LEVEL_PACKAGE_NAME: 'ghost_package'},
|
|
55
|
+
license='Apache-2.0',
|
|
56
|
+
description='Python rest server codegen for Le Comptoir Des Pharmacies',
|
|
57
|
+
long_description='Python rest server codegen for Le Comptoir Des Pharmacies',
|
|
58
|
+
author='Le Comptoir Des Pharmacies',
|
|
59
|
+
author_email='g.thrasibule@lecomptoirdespharmacies.fr',
|
|
60
|
+
url='https://bitbucket.org/lecomptoirdespharmacies/lcdp-openapi-codegen',
|
|
61
|
+
keywords=['openapi', 'python-fastapi-rest-server-codegen', 'openapi3'],
|
|
62
|
+
cmdclass={'build_py': CustomBuild},
|
|
63
|
+
)
|