Add SwaggerUI to your AWS Apigateway RestApi
Project description
CDK Apigateway SwaggerUI
Add SwaggerUI to your AWS Apigateway RestApi
Install
TypeScript
npm install @pepperize/cdk-apigateway-swagger-ui
or
yarn add @pepperize/cdk-apigateway-swagger-ui
Python
pip install pepperize.cdk-apigateway-swagger-ui
C# / .Net
dotnet add package Pepperize.CDK.ApigatewaySwaggerUi
Java
<dependency>
<groupId>com.pepperize</groupId>
<artifactId>cdk-apigateway-swagger-ui</artifactId>
<version>${cdkApigatewaySwaggerUi.version}</version>
</dependency>
Usage
import { Stack } from "aws-cdk-lib";
import * as apigateway from "aws-cdk-lib/aws-apigateway";
import { SwaggerUi } from "@pepperize/cdk-apigateway-swagger-ui";
const stack = new Stack();
const restApi = new apigateway.RestApi();
new SwaggerUi(stack, "SwaggerUI", { resource: restApi.root });
- Open your SwaggerUI:
https://<rest api id>.execute-api.<aws region>.amazonaws.com/<stage>/api-docs/swagger-ui.html
- View your API docs:
https://<rest api id>.execute-api.<aws region>.amazonaws.com/<stage>/api-docs.json
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for pepperize.cdk-apigateway-swagger-ui-0.0.382.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4e14334ce380d6caff6b0e96385cb18b6eedcb4baffc5fa1be7b085373f2b894 |
|
MD5 | 33042dcab85bf1b7607bf81411e14663 |
|
BLAKE2b-256 | 137fa9396873ec69f31a15f3dbc98a46466f0ec341283113f38b5056edd1e344 |
Close
Hashes for pepperize.cdk_apigateway_swagger_ui-0.0.382-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 58bd0cbd28e4fd4160d578d803bcdfbc93c3c70ca0a05806e1297dcd13e8826c |
|
MD5 | 2ef12c5424248893046f1bbd0ab66e70 |
|
BLAKE2b-256 | 8b9c0f8257ecefeb7d572a55b0709beb2271252fcac0bd0f9ae5091f81accbe7 |