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
- Update User Error
```ts const { users, databases } = await createAdminClient(); const session = await getLoggedInUser(); const user = await users.get(session.$id); if (!use...
- apple exchange code to token
hello guys, im new here 🙂 I have created a project and enabled apple oauth, filled all data (client id, key id, p8 file itself etc). I generate oauth code form...
- How to Avoid Double Requests in function...
I'm currently using Appwrite's `functions.createExecution` in my project. I want to avoid double requests when multiple actions (like searching or pagination) a...