Menu
companyContactAssignRole
Assigns a role to a contact for a location.
Use it in a workflow
- Add a step and choose the Shopify connector.
- Pick the companyContactAssignRole action (under Company).
- Fill in the fields below, then reference the result from later steps as
{{companycontactassignrole.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 CompanyContactAssignRole($companyContactId: ID!, $companyContactRoleId: ID!, $companyLocationId: ID!) {
companyContactAssignRole(
companyContactId: $companyContactId
companyContactRoleId: $companyContactRoleId
companyLocationId: $companyLocationId
) {
companyContactRoleAssignment {
company {
contactCount
contactsCount
createdAt
customerSince
defaultCursor
defaultRole
externalId
hasTimelineComment
id
lifetimeDuration
locationsCount
mainContact
name
note
ordersCount
totalSpent
updatedAt
}
companyContact {
company
createdAt
customer
id
isMainContact
lifetimeDuration
locale
title
updatedAt
}
companyLocation {
billingAddress
buyerExperienceConfiguration
company
createdAt
currency
defaultCursor
externalId
hasTimelineComment
id
locale
market
name
note
orderCount
ordersCount
phone
shippingAddress
taxExemptions
taxRegistrationId
taxSettings
totalSpent
updatedAt
}
createdAt
id
role {
id
name
note
}
updatedAt
}
userErrors {
code
field
message
}
}
}
Variables
Pass these as a JSON object in the step's Variables field.
{
"companyContactId": "string",
"companyContactRoleId": "string",
"companyLocationId": "string"
}
Response
Read the result with {{companycontactassignrole.response.data.data.companyContactAssignRole}}. If the API returns errors, the step fails and they are at {{companycontactassignrole.response.data.errors}}.
Need more? See the Shopify guide for connection setup and behaviour shared by every action.
Was this page helpful?