Is there a way to pass "variables" to schema.execute? In the same way Relay mutations input is passed, ideally.
It's not clear from the docs/code how I would do this.
I figured it out. It's the args keyword argument to schema.execute. It should be a dict (or other map type) and the keys should be camelCase. For example:
schema.execute(
'''
mutation UpdateItem($input_key: UpdateItemMutationInput!) {
updateItem(input: $input_key)
}
''',
args={
'input_key': {
'clientMutationId': 'whatever',
'someOtherInputValue': 42,
}
},
)
FYI - It appears as though args has been renamed variable_values.
Variables (instead of variable_values) worked for me
Most helpful comment
FYI - It appears as though
argshas been renamedvariable_values.