Problem
For websocket API calls that use stages the path gets removed from the URI resulting in something like this:
https://xxxxx.execute-api.us-east-1.amazonaws.com/dev/@connections/yyyyy
becoming:
https://xxxxx.execute-api.us-east-1.amazonaws.com/@connections/yyyyy
And thus a client forbidden error is thrown.
Solution
Two things must be set for the guzzlehttp resolver to properly blend the paths together.
ApiGatewayManagementApiClient call must have the trailing slash. IE:
https://xxxxx.execute-api.us-east-1.amazonaws.com/dev/
thus becoming:
"requestUri" : "@connections/{connectionId}",
I'm happy to do a PR for the one character removal if you want.
Hi @papacarp, thanks for reaching out to us about this. Unfortunately we won't be able to accept a PR for this change since the API model in the file you mention is provided by the API Gateway team; any update that gets pushed to this file from their end would overwrite this change.
I've reached out to the service team about having this change made to the API model from their end, once I have additional information I'll update the issue accordingly.
Is there a status update on this? The reporter of this issue has suggested a very simple fix. Please get this done, as it breaks the PHP SDK for web sockets. We obviously can patch it, but if there is a need to adhere to your internal process, that process shouldn鈥檛 take a 2 minute issue and turn it into one that takes two months.
A fix for this issue has been merged. It will be fixed with the next release.
Most helpful comment
Is there a status update on this? The reporter of this issue has suggested a very simple fix. Please get this done, as it breaks the PHP SDK for web sockets. We obviously can patch it, but if there is a need to adhere to your internal process, that process shouldn鈥檛 take a 2 minute issue and turn it into one that takes two months.