Piyush Bansal
Piyush Bansal

Reputation: 1723

How to pass variables in mutation graphQL Playground?

I am using apollo express server 2.0. And I am trying to execute mutation in the graphql playground. Here is the mutation I have attached a screenshot with another screenshot of a variable.

Mutation Command to create new user Mutation variables

I am getting the following error when I am trying to execute mutation command in the graphql playground.

enter image description here

Please guide me where I am incorrect.

Upvotes: 14

Views: 15473

Answers (2)

cuspymd
cuspymd

Reputation: 1088

There are two tabs QUERY VARIABLES and HTTP HEADERS in the input field at the bottom right of graphQL Playground. Please check the tab QUERY VARIABLES is selected.

Upvotes: 20

toonday
toonday

Reputation: 571

Seems you have to define each of the input fields separately.

Upvotes: -1

Related Questions