aws-prototyping-sdk.type-safe-api


Nameaws-prototyping-sdk.type-safe-api JSON
Version 0.19.68 PyPI version JSON
download
home_pagehttps://github.com/aws/aws-prototyping-sdk
Summary@aws-prototyping-sdk/type-safe-api
upload_time2023-08-24 23:17:35
maintainer
docs_urlNone
authorAWS APJ COPE<apj-cope@amazon.com>
requires_python~=3.7
licenseApache-2.0
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Type Safe API

Define your APIs using [Smithy](https://smithy.io/2.0/) or [OpenAPI v3](https://swagger.io/specification/), and leverage the power of generated client and server types, infrastructure, documentation, and automatic input validation!

This package vends a projen project type which allows you to define an API using either [Smithy](https://smithy.io/2.0/) or [OpenAPI v3](https://swagger.io/specification/), and a construct which manages deploying this API in API Gateway, given an integration (eg a lambda) for every operation.

The project will generate "runtime" projects from your API definition in your desired languages, which can be utilised both client side for interacting with your API, or server side for implementing your API. The project also generates a type-safe CDK construct which ensures an integration is provided for every API operation.

Code is generated at build time, so when you change your API model, just rebuild and you'll see your changes reflected in the generated code.

### Project Structure

The `TypeSafeApiProject` projen project will create the following directory structure within its `outdir`:

```
|_ model/
    |_ src/
        |_ main/
            |_ smithy - your API definition if you chose ModelLanguage.SMITHY
            |_ openapi - your API definition if you chose ModelLanguage.OPENAPI
|_ generated/
    |_ runtime/ - generated types, client, and server code in the languages you specified
        |_ typescript
        |_ python
        |_ java
    |_ infrastructure/ - generated infrastructure (you'll find only one directory in here based on your chosen infrastructure language)
        |_ typescript
        |_ python
        |_ java
    |_ documentation/ - generated documentation in the formats you specified
        |_ html2
        |_ html_redoc
        |_ plantuml
        |_ markdown
    |_ library/ - generated libraries if specified
        |_ typescript-react-query-hooks
```

### Getting Started

Please see the [Getting Started Guide](docs/developer_guides/type-safe-api/index.md) for how to get started!

### Developer Guides

For more information about Type Safe API, take a look at the developer guides:

* [Using Smithy](docs/developer_guides/type-safe-api/using_smithy.md)
* [Using OpenAPI](docs/developer_guides/type-safe-api/using_openapi.md)
* [Integrations](docs/developer_guides/type-safe-api/integrations.md)
* [Mocking Responses](docs/developer_guides/type-safe-api/mocking_responses.md)
* [Authorizers](docs/developer_guides/type-safe-api/authorizers.md)
* [Lambda Handlers](docs/developer_guides/type-safe-api/lambda_handlers.md)
* [React Query Hooks](docs/developer_guides/type-safe-api/typescript_react_query_hooks.md)
* [API Keys](docs/developer_guides/type-safe-api/api_keys.md)

### Walkthroughs

For detailed end-to-end examples, take a look at the walkthroughs:

* [Custom Integration: ECS and NLB](docs/walkthroughs/type-safe-api/custom_integration_ecs.md)

You can also check out the [Frequently Asked Questions](docs/faqs/type-safe-api/index.md).



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/aws/aws-prototyping-sdk",
    "name": "aws-prototyping-sdk.type-safe-api",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "~=3.7",
    "maintainer_email": "",
    "keywords": "",
    "author": "AWS APJ COPE<apj-cope@amazon.com>",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/57/5a/2ff4e211e8e432dd6c8b0ac4b3ebff32402ff52ff6520b8d2e322c1c9c8e/aws_prototyping_sdk.type_safe_api-0.19.68.tar.gz",
    "platform": null,
    "description": "# Type Safe API\n\nDefine your APIs using [Smithy](https://smithy.io/2.0/) or [OpenAPI v3](https://swagger.io/specification/), and leverage the power of generated client and server types, infrastructure, documentation, and automatic input validation!\n\nThis package vends a projen project type which allows you to define an API using either [Smithy](https://smithy.io/2.0/) or [OpenAPI v3](https://swagger.io/specification/), and a construct which manages deploying this API in API Gateway, given an integration (eg a lambda) for every operation.\n\nThe project will generate \"runtime\" projects from your API definition in your desired languages, which can be utilised both client side for interacting with your API, or server side for implementing your API. The project also generates a type-safe CDK construct which ensures an integration is provided for every API operation.\n\nCode is generated at build time, so when you change your API model, just rebuild and you'll see your changes reflected in the generated code.\n\n### Project Structure\n\nThe `TypeSafeApiProject` projen project will create the following directory structure within its `outdir`:\n\n```\n|_ model/\n    |_ src/\n        |_ main/\n            |_ smithy - your API definition if you chose ModelLanguage.SMITHY\n            |_ openapi - your API definition if you chose ModelLanguage.OPENAPI\n|_ generated/\n    |_ runtime/ - generated types, client, and server code in the languages you specified\n        |_ typescript\n        |_ python\n        |_ java\n    |_ infrastructure/ - generated infrastructure (you'll find only one directory in here based on your chosen infrastructure language)\n        |_ typescript\n        |_ python\n        |_ java\n    |_ documentation/ - generated documentation in the formats you specified\n        |_ html2\n        |_ html_redoc\n        |_ plantuml\n        |_ markdown\n    |_ library/ - generated libraries if specified\n        |_ typescript-react-query-hooks\n```\n\n### Getting Started\n\nPlease see the [Getting Started Guide](docs/developer_guides/type-safe-api/index.md) for how to get started!\n\n### Developer Guides\n\nFor more information about Type Safe API, take a look at the developer guides:\n\n* [Using Smithy](docs/developer_guides/type-safe-api/using_smithy.md)\n* [Using OpenAPI](docs/developer_guides/type-safe-api/using_openapi.md)\n* [Integrations](docs/developer_guides/type-safe-api/integrations.md)\n* [Mocking Responses](docs/developer_guides/type-safe-api/mocking_responses.md)\n* [Authorizers](docs/developer_guides/type-safe-api/authorizers.md)\n* [Lambda Handlers](docs/developer_guides/type-safe-api/lambda_handlers.md)\n* [React Query Hooks](docs/developer_guides/type-safe-api/typescript_react_query_hooks.md)\n* [API Keys](docs/developer_guides/type-safe-api/api_keys.md)\n\n### Walkthroughs\n\nFor detailed end-to-end examples, take a look at the walkthroughs:\n\n* [Custom Integration: ECS and NLB](docs/walkthroughs/type-safe-api/custom_integration_ecs.md)\n\nYou can also check out the [Frequently Asked Questions](docs/faqs/type-safe-api/index.md).\n\n\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "@aws-prototyping-sdk/type-safe-api",
    "version": "0.19.68",
    "project_urls": {
        "Homepage": "https://github.com/aws/aws-prototyping-sdk",
        "Source": "https://github.com/aws/aws-prototyping-sdk"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ecaea468235102932ac6ccecea67c4b5db0e68bb3becb2b82429eb336a28c687",
                "md5": "8995905871d7abcd3fc76dfd2b7c5785",
                "sha256": "07d8b6fbf2f0123087c23e2fe5b96d8bb624e5cb981d9e5cb414c250be7ebf2c"
            },
            "downloads": -1,
            "filename": "aws_prototyping_sdk.type_safe_api-0.19.68-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "8995905871d7abcd3fc76dfd2b7c5785",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "~=3.7",
            "size": 1522422,
            "upload_time": "2023-08-24T23:17:34",
            "upload_time_iso_8601": "2023-08-24T23:17:34.054001Z",
            "url": "https://files.pythonhosted.org/packages/ec/ae/a468235102932ac6ccecea67c4b5db0e68bb3becb2b82429eb336a28c687/aws_prototyping_sdk.type_safe_api-0.19.68-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "575a2ff4e211e8e432dd6c8b0ac4b3ebff32402ff52ff6520b8d2e322c1c9c8e",
                "md5": "92996d68c95e0b03059684b6555f3825",
                "sha256": "1bb960a961d5057f3bf702e8bb23780a445f942edacfe90df10657e8ab53757d"
            },
            "downloads": -1,
            "filename": "aws_prototyping_sdk.type_safe_api-0.19.68.tar.gz",
            "has_sig": false,
            "md5_digest": "92996d68c95e0b03059684b6555f3825",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "~=3.7",
            "size": 1521619,
            "upload_time": "2023-08-24T23:17:35",
            "upload_time_iso_8601": "2023-08-24T23:17:35.711355Z",
            "url": "https://files.pythonhosted.org/packages/57/5a/2ff4e211e8e432dd6c8b0ac4b3ebff32402ff52ff6520b8d2e322c1c9c8e/aws_prototyping_sdk.type_safe_api-0.19.68.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-08-24 23:17:35",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "aws",
    "github_project": "aws-prototyping-sdk",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "aws-prototyping-sdk.type-safe-api"
}
        
Elapsed time: 0.10621s