I encountered with this error when the path parameter I used was an unencoded value.
Example API GW path:
/accounts/{accountId}/files/{fileId}
In case the fileId
contains slash character (eg. file/123
) the error occurs.
Fix:
URL-encode the path parameters when calling the API:
/accounts/123/files/file%2F123