Referencing websocket api id in serverless template

0

To get the REST Api Gateway Id we can use something like this:

provider:
environment:
GW_URL:
Fn::Join:
- ""
- - "https://"
- Ref: "ApiGatewayRestApi"
- ".execute-api.${self:custom.region}.amazonaws.com/${self:custom.stage}"

See http://www.goingserverless.com/blog/api-gateway-url

I have added a websocket api gateway and would like to get the endpoint of it just like the rest api endpoint.

Compare:
GET - https://chjpngb443.execute-api.eu-central-1.amazonaws.com/test/facebook/messages
wss://rs1ekw8ha0.execute-api.eu-central-1.amazonaws.com/test

Note that the rest api and websocket api have differing ids, chjpngb443 and rs1ekw8ha0 respectively.

I couldn’t find a suitable Ref variable for the websocket api id. Does anyone know how to get this property?

質問済み 5年前492ビュー
1回答
0
回答済み 5年前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ