CORS error using the Locale API from a browser: CORS Allow Origin Not Matching Origin
- 0
- Self Hosted
- Web
When I call the GET /v1/locale API with JS in a browser the GET request fails with CORS Allow Origin Not Matching Origin.
Requests to GET /v1/databases/... work fine and return the correct access-control-allow-origin header (domain.com), but the /v1/locale returns the Appwrite url only (api.domain.com).
The OPTION request for the locale also succeeds with the correct header.
I have added the domain as a platform in the console.
Are you including your project ID in the request header?
Yes, it's sent in the X-Appwrite-Project header. The Databases API and Account API work but not the Locale API
Can you share the code with me?
Only the part where you're handling this
And have you added your domain in the platform?
Recommended threads
- Selfhost - Starting Docker containers fa...
I am stuck at installing appwrite. Specifically, the containers dont want to start up. The images are downloaded and ready. Dockhand is reporting containers st...
- It says domain already used but I have d...
I accidentally deleted the project in which I used my domain originally (orexia.app) from name.com. Now I am trying to add it to a different project and it says...
- Is this normal in the self host custom d...
when i try to add custom domain to the project did not see this in 1.8.0 ok when pressed the retry it says "DNS verification failed with resolver 8.8.8.8. Domai...