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.643.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | eaa05df47483ab235250fdfc5fe34d157c0c762804178eb51cfc4e14f842583b |
|
MD5 | 138aaf48e3af0fcc6cb0ae639c0d0646 |
|
BLAKE2b-256 | fdee7b94723690bf94ff8f559e7b188db954842ec6c5e0ccf83d9664b88c36b9 |
Close
Hashes for pepperize.cdk_apigateway_swagger_ui-0.0.643-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d537d0549a526f54dfcb9dbfe63bf28bb92e3fbcb429083a53e0a33788b1bbbd |
|
MD5 | 5a3eda5777d30203ccd07b6014578200 |
|
BLAKE2b-256 | f5efe10ba13f7a03c3c10d50f4dd44c5c4e3d1780c90cf513640a835cf780d9a |