Trying to get my flowTriggerReceivemutation to work but it keeps telling me I have issues with `order_id`.
$flow_mutation = [
'query' => '
mutation flowTriggerReceive($handle: String!, $payload: JSON!) {
flowTriggerReceive(handle: $handle, payload: $payload) {
userErrors {
field
message
}
}
}
',
'variables' => [
'handle' => 'order-tag-updated',
'payload' => [
'order_id' => $order_id,
'tagAdded' => $tag_added,
]
]
];
First it tells me:
[{“field”:[“body”],“message”:"Errors validating schema:\n Required field missing: ‘order_id’.\n”}]
Then I add order_id and it tells me I have Type errors:
[{“field”:[“body”],“message”:“Errors validating schema:\n Type error for field ‘order_id’: gid://shopify/Order/6826489905324 is not an Order.\n”}]
I tried just the INT and it still didnt work:
[{“field”:[“body”],“message”:“Errors validating schema:\n Type error for field ‘order_id’: 6826489905324 is not an Order.\n”}]
The order is indeed an actual order.
In my TOML:
[settings]
[[settings.fields]]
type = “order_reference”