Use GraphiQL interface without having a proper login interface.
As we're using the lexik JWT bundle and security rules on the graphql endpoint, we generally need a connection token to carry out queries via GraphiQL.
-
Import this API collection into Postman and login as a User or Admin.
-
Copy/Paste the response token into .env.local like :
###> graphiql ###
GRAPHIQL_JWT_TOKEN="token-jwt-azertyuiopqsdfghjklmwxcvbn"
###< graphiql ###
Tip
If you've already developed a login interface, you can use it to get a token.
Don't forget to install GraphQL extention to your IDE and generate the schema.graphql
See this introduction and documentation about exploring data with GraphiQL.