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.195.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | cc8958fb2e92a5dc4ce463a9bbfc41c0a75f58413104d2c365f2aac3e0a327aa |
|
MD5 | 94a8fb09e4fc53f0db9e6e991e34dbf7 |
|
BLAKE2b-256 | 6f044954b3d8048754afbcd08031cfa85fefc94c8333ff513d740a35e053bed5 |
Close
Hashes for pepperize.cdk_apigateway_swagger_ui-0.0.195-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e3c3ac0843f7898b3fed574a7f5ac4b7a3ca58a8dea780e1297f31d28c537c1 |
|
MD5 | bab222d32879ccd18cc53121d4c42e10 |
|
BLAKE2b-256 | da71b7abae6ede92d94b5d18b26ee18cb26bf81f2a96939c1060b2506eea8c81 |