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.895.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2aa80c4376674770e0a88d9f652e06a82029150ee1587f338f4d4a735922c74d |
|
MD5 | 84bb3eafb97814fbe96efb20c8432fd5 |
|
BLAKE2b-256 | bcd2ed934210500059b6393b1fdc5da25b1c4072d90c58bb939e69a9519c6484 |
Close
Hashes for pepperize.cdk_apigateway_swagger_ui-0.0.895-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 44c2aa152790977cdf24f43914a7ca39e4deeb8f31bcf1c528c5135196b3c630 |
|
MD5 | a9524bd1e88065b6ad6a0aa8be69dd0c |
|
BLAKE2b-256 | f1ad2d0e8412b6798d36bd99175e506f95103f736884c558cb8d941dc6ae2163 |