How to receive POST requests on AWS Beanstalk on a different resource than root?

I'd like to run a webhook proxy on AWS Beanstalk. The service sends POST requests, which need to be modified and forwarded by the proxy.

The URL to wich the POST would be directed is something like<randomid>

Unfortunately this doesn't seem to work. When the webhook is sent to the proxy I only the following error message:

MethodNotAllowed - The specified method is not allowed against this resource

I found that AWS only allows POST requests to the root resource. Are there any settings which need to be applied on the AWS side to enable POST to this resource?