title: Authentication and Authorization with Django GraphQL JWT and Graphene Relay
body: <p>I would like to ask how I can do authentication and query tags limited to a specific user (owner) using Graphen Relay and Django JWT.
  Here is my Model:</p>
  
  <pre><code>class Tag(models.Model):
  """Tag to be used for a objective"""
  name = models.CharField(max_length=255)
  user = models.ForeignKey(
      settings.AUTH_USER_MODEL,
      related_name='tag',
      on_delete=models.CASCADE,
  )
  </code></pre>
  
  <p>Here is my Schema code:</p>
  
  <pre><code>class TagNode(DjangoObjectType):
  class Meta:
      model = Tag
      filter_fields = ['name']
      interfaces = (relay.Node,)
  </code></pre>
  
  <p>Here is my Query:</p>
  
  <pre><code>class Query(graphene.ObjectType):
      tag = relay.Node.Field(TagNode)
      all_tags = DjangoFilterConnectionField(TagNode)
  
      def resolve_all_tags(self, info):
  
          # context will reference to the Django request
          print(info.context.user)
          if not info.context.user.is_authenticated:
              return Tag.objects.none()
          else:
              return Tag.objects.filter(user=info.context.user)
  </code></pre>
  
  <p>Here is the document for Django JWT: <a href="https://github.com/flavors/django-graphql-jwt" rel="nofollow noreferrer">https://github.com/flavors/django-graphql-jwt</a> but I do not know how to get the user (already use info.context.user) but it does not work,
  when I tried to add Authorization (JWT token) in the header or as an argument. It also does not work.</p>