Users
query {
users(limit: 3, order: desc) {
id
firstName
lastName
email
}
}
User
query {
user(id: 1){
id
firstName
lastName
email
}
}
User update
mutation updateUser($id: Int!, $firstName: String!, $lastName: String!) {
updateUser(id: $id, firstName: $firstName, lastName: $lastName) {
id
firstName
lastName
email
}
}
#
mutation SignIn($email: String!, $password: String!) {
signIn(email: $email, password: $password) {
id
firstName
lastName
email
refreshToken
accessToken
}
}
#
mutation #($email: String!, $password: String!) {
#(email: $email, password: $password) {
id
firstName
lastName
email
refreshToken
accessToken
}
}
Current user
query currentUser{
currentUser{
id
firstName
lastName
email
refreshTokens{
id
browserName
deviceName
osName
userAgent
token
createdAt
}
}
}
Destroy refresh token
mutation destroyRefreshToken($id: Int!) {
destroyRefreshToken(id: $id) {
id
}
}