ApiGateway WebSocket - How to override requestId? Or any other way to get reception confirmation of messages sent.

0

Hi, ApiGateway docs says that it is possible to override requestId with HTTP by overriding a header. But it says nothing about a way to do it when using websockets. How can i override requestId to get confirmation that message was well received? by requestId or any other solution identifying my sent message, It must be handled directly by ApiGateway, and not depending on a Lambda triggered or any consuming processing... I already have a integration response, and get for exampleconnectinId properly, but the requestId being generated by ApiGateway itself, i cant indetify back the sent message myself. Thanks

1 Risposta
0

When using WebSockets, the connection is established once using HTTP. From that point you send messages over the existing connections, not using HTTP protocol, so there are no HTTP headers and there are no request IDs.

There might be some ACK in the web sockets protocol itself, but if you want to be sure, you need to send an ACK from the backend.

profile pictureAWS
ESPERTO
Uri
con risposta un anno fa
  • Thanks, ok but i thought that AWS Apigateway had a way to override responseID in the socket messages itself. as it will already read the json in the sent message to get the route name, it could also read a requestID to use it instead of generating one.

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande