Closed Blooon closed 2 years ago
Routing to @getsentry/app-frontend for triage. ⏲️
d '{"eventId":"d78258e2dc5540939f6f0a6f9a39b71e",
The request parameter is event_id
not eventId
.
Indeed, my mistake.. 🤦♂️ However I still have the same issue with event_id.
Ok. The reason you're getting a 404 is that your URL is missing the trailing slash https://sentry.io/api/0/projects/<our_company>/<our_project>/user-feedback
needs to be https://sentry.io/api/0/projects/<our_company>/<our_project>/user-feedback/
.
Hi ! It is working with the additional trailing slash ! Never saw an API endpoint with a trailing slash like that, but anyway it solves my issue. Thanks a lot for the help ! :)
Environment
SaaS (https://sentry.io/)
Version
No response
Steps to Reproduce
Hi !
I'm trying to make a custom User Feedback dialog integration in our React project (@sentry/react v7.12.1) and therefore I try to send the user feedback data myself in our frontend client using POST to https://sentry.io/api/0/projects///user-feedback API endpoint, as described in your doc.
However I'm getting a CORS error when POSTing the data. In DevTools the request's status returns : "Cross-Origin Resource Sharing error: PreflightMissingAllowOriginHeader".
Regarding request's headers, Authorization is made using our DSN and Content-Type is "application/json" as mentioned is the doc.
Expected Result
The user feedback data should be POSTed via the Sentry API for the corresponding issue.
Actual Result
a CORS error when POSTing the data. In DevTools the request's status returns : "Cross-Origin Resource Sharing error: PreflightMissingAllowOriginHeader".
I've tried the same request using Postman but this leads to a 404 Not Found whereas the issue with the corresponding event_id does exist in our Sentry Issues.
Using Curl returns a 404 as well :
As far as I've seen, it seems to be a quite common issue when trying to use an API endpoint. But I couldn't find any issue providing a matching solution. Thus, I'm unsure if that's a problem from your side or a missing config from ours. Just let me know.