execute_mutation
Execute a GraphQL mutation by providing a raw mutation string and optional variables to modify server data.
Instructions
Send a raw GraphQL mutation string to the endpoint. Functionally identical to execute_query — use whichever is more semantically clear. Not idempotent: mutations can have side effects.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"mutation": "<mutation>"
},
"name": "execute_mutation"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mutation | Yes | GraphQL mutation string. Example: 'mutation { updateUser(id: 42, input: {...}) { id } }' | |
| variables | No | Variables to pass alongside the mutation. Use $varName in the mutation to reference them. | |
| operation_name | No | If the mutation contains multiple operations, the name of the one to execute. |