Recent searches
No recent searches
authenticity_token doesn't work on host mapped helpcenter
Posted May 31, 2021
Unfortunately, the authenticityToken solution provided in the below article doesn't work if your helpcenter is host mapped. I get a 403 error message and support have confirmed that it's an issue. My use case requires the token in order to make api calls to the subscription endpoint for users logged into the helpcenter.
https://developer.zendesk.com/apps/docs/help-center-templates/v1
For those who were stuck, there's an undocumented way of getting it. If you make a call to /hc/api/internal/csrf_token.json, you'll be able to access an object containing current_session_csrf_token. This token will work on host mapped helpcenters. It's undocumented so be prepared for it to disappear at some point in the future.
0
2 comments
Ignacio Fernandez
I'm experiencing the same issue, requests using authenticity token return a 403 error when the API domain is under the hosted mapped domain. Switching the subdomain.zendesk.com works, however, this forces users to allow third-party cookies.
Is there any workaround for this?
0
Kacey Zeccola
I see that you have a private ticket open with our team - they will continue to investigate this with you, but let us know if you have any other questions.
0