We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am using Micronaut GraphQL with Kickstart tool (https://github.com/graphql-java-kickstart/graphql-java-tools). How can I get HTTP request headers in GraphQL resolvers?
The text was updated successfully, but these errors were encountered:
@tuanlt2 take a look at the GraphQLExecutionInputCustomizer interface.
Sorry, something went wrong.
@tuanlt2 please check jwt-security example: https://github.com/micronaut-projects/micronaut-graphql/tree/master/examples/jwt-security.
jwt-security
It uses custom GraphQLExecutionInputCustomizer implementation: https://github.com/micronaut-projects/micronaut-graphql/blob/bb9004086874f450e7f7502a3c16107c0346b7ae/examples/jwt-security/src/main/java/example/graphql/RequestResponseCustomizer.java
GraphQLExecutionInputCustomizer
And after that inside the resolver, you can get the request object from the context:
micronaut-graphql/examples/jwt-security/src/main/java/example/graphql/LoginDataFetcher.java
Line 86 in 766cccb
No branches or pull requests
I am using Micronaut GraphQL with Kickstart tool (https://github.com/graphql-java-kickstart/graphql-java-tools).
How can I get HTTP request headers in GraphQL resolvers?
The text was updated successfully, but these errors were encountered: