I've setup a locale environment within docker, created a database and a web app with corresponding hostname. I'm able to use the .listDocuments API. But when I try to use GraphQL, I get a CORS error.
Also when I want to access the GraphQL Explorer through Altair, I'm not able to load the schema/docs. _APP_OPTIONS_ABUSE is set as disabled as advised by https://gist.github.com/stnguyen90/8b6b80682d80cfec130a61e60e07d1f9#file-start-appwrite-graphql-explorer-sh-L3.
What should I do extra to avoid the CORS errors for GraphQL from within my web app? And how to access through the GraphQL Explorer/Altair?
Where are you making the API calls from?
A web app? Did you add the web app as a web platform?
Both from a web app and from the GraphQL playground (Altair). The web app is added as web platform.
I though, I would be able to create my own GraphQL queries/mutation. But apparently only those provided within the docs are available., right?
Something like query {
todos(
databaseId: "655502fec6ccfd1dbd82"
) {
_id
description
}
} won't be possible, I guess?
Did you have added a platform in the console with the corresponding domain?
Yes, the platform is added with the corresponding domain. It's working fine. I wrongly thought, I could create my own GraphQL queries/mutations as I mentioned above. Apparently, it's not possible. Only those from the docs are supported, which makes GraphQL a less interesting option unfortunately. Anyway, the service as a whole is awesome.
Recommended threads
- How to handle ghost accounts created by ...
Appwrite create the account with the email and send an invitation link with a secret. I am able to accept the invitation and add the account as a member on the ...
- Re-connect site to domain verification f...
I have mistakenly deleted appwrite site without removing domain. Now I created same site and want to re-connect my domain. It gives this error while verify. How...
- SSR share session to client using custom...
Hi, so I was trying to get a hang of using SSR and using realtime updates in the same time which is done easiest if you have a custom domain in Appwrite and as ...