Created
September 9, 2016 05:26
-
-
Save tonyxiao/043a68bce4cdd43d457c03f1d98a133a to your computer and use it in GitHub Desktop.
GraphQL authentication
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
router.post('/graphql', (ctx) => { | |
return apolloKoa({ | |
schema: executableSchema, | |
context: { | |
headers: ctx.request.headers, | |
}, | |
printErrors: true, | |
})(ctx) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment