Skip to content

Instantly share code, notes, and snippets.

@tonyxiao
Created September 9, 2016 05:26
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save tonyxiao/043a68bce4cdd43d457c03f1d98a133a to your computer and use it in GitHub Desktop.
GraphQL authentication
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