Menu
orderAttributionDefinitionUpsert
Upserts an order attribution definition for the calling app on the current shop. Apps can use attribution definitions to label orders they route to a shop, replacing or augmenting any definitions shipped…
Use it in a workflow
- Add a step and choose the Shopify connector.
- Pick the orderAttributionDefinitionUpsert action (under Order).
- Fill in the fields below, then reference the result from later steps as
{{orderattributiondefinitionupsert.response.data}}.
Query
This is the mutation the action sends by default. Edit it in the step's Query field to change which fields come back.
mutation OrderAttributionDefinitionUpsert($input: OrderAttributionDefinitionUpsertInput!) {
orderAttributionDefinitionUpsert(input: $input) {
orderAttributionDefinition {
displayName
handle
icon
id
}
userErrors {
code
field
message
}
}
}
Variables
Pass these as a JSON object in the step's Variables field.
{
"input": {
"handle": "string",
"displayName": "string",
"icon": "string"
}
}
Response
Read the result with {{orderattributiondefinitionupsert.response.data.data.orderAttributionDefinitionUpsert}}. If the API returns errors, the step fails and they are at {{orderattributiondefinitionupsert.response.data.errors}}.
Need more? See the Shopify guide for connection setup and behaviour shared by every action.
Was this page helpful?