Hey
I was looking on resources about authentifying query in graphql?
(in a headless wordpress, I want to create a preview page, which needs authorization, but there is so many others use cases !).
I've found many informations on graphql doc.
with JTW plugin, I can get auth token to authentify graphql query. But it is not recommended to extend expiration delay with defaut 300 seconds.
So I have to get user auth token when my query is sent.
The best way seems to use wordpress session credentials, which is possible thanks to WPGraphQL CORS plugin.
Now I need to add "credentials : include" to my graphql query, but this field doesn't exist in graphql panel in webstudio.
Is there an other way to achieve this ?
I share you the script I used to achieve this but I would prefer a no-code way !!
Is it possible to add the "credentials: include" attribute in the graphql configuration?
Add a reply
Sign up and join the conversation on Discord