oai-sam is a script generating a SAM template together with OpenAPI documentation including AWS OpenAPI extensions from an OpenAPI/swagger documentation.
Simply provide your OpenApi/Swagger as an input and then use SAM CLI to deploy a working AWS ApiGateway.
Install
pip install oai-sam
Usage
Generate
oai-sam -f <OPENAPI_DOCS> -u <BACKEND_URL> -c <CORS_ORIGINS>
e.g:
oai-sam -f https://petstore.swagger.io/v2/swagger.json -u http://petstore.swagger.io/v2 -c "*"
Deploy AWS ApiGateway
- Install SAM CLI
sam package --template-file out/apigateway.yaml --s3-bucket <SAM_BUCKET> --output-file packaged.yaml(See sam package for more options)sam deploy --template-file packaged.yaml(See sam deploy for more options)
Show list of available arguments
oai-sam --help
Metadata
Release files for oai-sam 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| oai-sam-0.0.1.tar.gz | 14.5 kB | Without provenance | Details for oai-sam-0.0.1.tar.gz |
Release files / oai-sam-0.0.1.tar.gz
| Download URL | oai-sam-0.0.1.tar.gz |
|---|---|
| Size | 14.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1b59eb04745bf20e92e7c02ad19a375a892cdaeeb77d0b9aef21a08dfc41a213
|
|
BLAKE2b-256 checksum How to use checksums |
b000656a130c208c0942593ab8aa84f7a511639e7d8e26e5d8308542d696d229
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.8.0
|
Security for oai-sam 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.