PedroBern/django-graphql-auth

How to let users update thier own user profiles with token?

timytomy opened this issue · 0 comments

I want users to update thier own user profiles so I used "updateAccount" as shown below but, the error "Unauthenticated" occurred even though the account is verified and logged in.
:

mutation {
  updateAccount(
    firstName: "John"
  ) {
    success,
    errors
  }
}

So, I added "token" as shown below but the error "Unknown argument "token" on field "updateAccount" of type "Mutation"." occurred:

mutation {
  updateAccount(
    token: "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJlbWFpbCI6ImthenlhLml0by5kcmVhbUBnbWFpbC5jb20iLCJleHAiOjE2NTM4NzY0NDgsIm9yaWdJYXQiOjE2NTM4NzYxNDh9.2yyp9k86V_0AoiPJFmxTE6__-q1n4cWNysOw8bNIDqA"
    firstName: "John"
  ) {
    success,
    errors
  }
}

Are there any ways to let users to update thier own user profiles?