The significance of the string immediately after query type (query / mutation) GraphQL

Viewed 8052

I was wondering what the significance of the string that follows the query type, in this case "ProvisionQueues", it seems removing this from the string doesn't affect anything - is it just for logging or something. meta data?

mutation ProvisionQueues {
 createQueue(name: "new-queue") {
    url
  }
}
2 Answers

Adding to @Eric's answer with another example.

query allNotifications {
  notifications {
    success
    errors
    notifications {
      id
      title
      description
      attachment
      createdAt
    }
  }
}    ​
​
query {
  users {
    errors
    success
    users {
      id
      fullName
    }
  }
}

Notice above that the users query has no operation name. This can be resolved as below. ​

query allUsers {
  users {
    errors
    success
    users {
      id
      fullName
      mohalla
    }
  }
}
Related