Authentication issues (CSRF Verification Failed)

Since there’s no API for user feedback on iOS anymore, I’m following this GitHub issue in trying to manually send messages to that endpoint.

I’m trying to get this to work using curl but now I can’t get past a “CSRF Verification Failed” error page.

The request (from here) is as follows:

curl -d ‘{“event_id”:“1234”,“name”:“Nick”,“email”:“nick@example,com”,“comments”:“Hello World”}’
-H ‘Content-Type: application/json’
-H ‘Authorization: DSN hxxps://xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx@sentry.io/#######’
-X POST hxxps://sentry.io/api/0/projects/org-name/project-name/user-feedback/

We’re running on premise, but I just checked on sentry,io and it’s the same problem there.

The event_id I got from an our iOS app running in the simulator.

How to correctly authenticate?

PS: I had to hxxp and example,com because spam protection here