polar
polar copied to clipboard
Document what to do when webhook deliveries return a 3XX status code
trafficstars
- In the webhooks documentation, explain what to do if the status code returned is a redirection (3XX) status code.
- In the webhooks deliveries list, add a tooltip/link to this documentation if the status code is a 3XX status code
Original issue
Description
I have an API that host at Vercel and then I config Polar's webhook with it
URL: https://{DOMAIN}/api/webhook-polar
Then all webhook requests receive a 307 from my API.
Then I changed the URL to https://www.{DOMAIN}/api/webhook-polar and all the webhook requests now receive 200 from my API
The root cause is because Vercel has a redirect from non-www to www, so I think this should be automatically handled by Polar to prevent this case.
Current Behavior
Polar dashboard show all webhook request call return 307 and count as failed request
Expected Behavior
Webhook's request should receive 200 from my API
Screenshots
N/A
Environment:
- Operating System: macOS
- Browser (if applicable): Chrome