How can I add authorizations to some resolvers?
# orm-help
g
How can I add authorizations to some resolvers?
m
There is a great example for getting started with authenticating users: https://github.com/graphql-boilerplates/node-graphql-server/tree/master/advanced
m
For authorization (ie, providing authenticated users access to specific resources based on something like β€˜role’), try directives.
g
thanks guys, take a look!! πŸ˜‰
l
Here's my article for quick permissions. Graphql-tools is moving to
SchemaDirectives
instead of directive resolvers, but they are not deprecated at this point and won't be hard to transition if/when the time comes. https://blog.graph.cool/graphql-directive-permissions-authorization-made-easy-54c076b5368e
πŸ‘ 1
g
Thank you very much! It has been very helpful @lawjolla
πŸ˜„ 1
πŸ€—