[英]How can I configure different endpoints for different stages using NLB and HTTP API type in AWS API Gateway?
[英]How can I export the AWS API Gateway Endpoints to file (or similar) after deploying?
我正在使用 AWS API 网关模拟不同的 API,我想在我的应用程序(不是 lambda)中使用这些端点。
所以我的想法是以某种方式从 json 之类的文件中引用这些端点,但为此我需要在每次部署时导出它们。
有什么办法可以存档吗?
这取决于您使用哪个堆栈来部署 API 网关。
例如,
Outputs:
myapi:
Type: AWS::ApiGatewayV2::Api
Properties:
Name: MyAPI
ProtocolType: HTTP
APIEndpoint:
Description: endpoint of api
Value:
Fn::Join:
- ""
- - https://
- Ref: myapi
- .execute-api.ap-southeast-1.amazonaws.com/
Export:
Name: APIEndpoint
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.