Closed ondrejehrlich closed 1 year ago
Create a new Websocket API. Enter a name and leave the route selection expression to what it is. Add a $disconnect and $default. Set both integrations to Lambda and select your CLI lambda from the list. Set the name of the stage to what you desire and create the API. Once created, write down the ID, as we'll need it later.
Your Vapor setup should generate 3 Lambda functions: http (your-app
), artisan (your-app-artisan
) and queue (your-app-queue
). The artisan one is the one you should link.
Thank you. I'm closing the issue.
I struggle to set up this with Laravel Vapor deployment. I've created API gateway (websockets), and DynamoDB table as described. I also set the right permissions to laravel-vapor-role. But when I connect to the websockets API from the frontend or terminal, the connectionID is not created in the DynamoDB and when I insert the connectionID by hand into the DynamoDB the message is still not sent to the client. What code should be there in the AWS Lambda to make this happen?