Anchor to companyAssignMainContactcompany
companyAssignMainContact
mutation
Requires access scope or
access scope. Also: The API client must be installed on a Shopify Plus store.
Assigns the main contact for the company.
Anchor to Arguments
Arguments
- Anchor to companyContactIdcompany•
Contact Id ID!required The ID of the company contact to be assigned as the main contact.
- Anchor to companyIdcompany•
Id ID!required The ID of the company to assign the main contact to.
Was this section helpful?
Anchor to CompanyAssignMainContactPayload returnsCompanyAssignMainContactPayload returns
- Anchor to companycompany•
The company for which the main contact is assigned.
- Anchor to userErrorsuser•
Errors [BusinessCustomer non-nullUser Error!]! The list of errors that occurred from executing the mutation.
Was this section helpful?
Mutation Reference
mutation companyAssignMainContact($companyContactId: ID!, $companyId: ID!) {
companyAssignMainContact(companyContactId: $companyContactId, companyId: $companyId) {
company {
# Company fields
}
userErrors {
field
message
}
}
}
Input
{
"companyContactId": "gid://shopify/<objectName>/10079785100",
"companyId": "gid://shopify/<objectName>/10079785100"
}
{
"companyContactId": "gid://shopify/<objectName>/10079785100",
"companyId": "gid://shopify/<objectName>/10079785100"
}