Anchor to companyLocationCreatecompany
companyLocationCreate
mutation
Requires access scope or
access scope. Also: The API client must be installed on a Shopify Plus store.
Creates a company location.
Anchor to Arguments
Arguments
- Anchor to companyIdcompany•
Id ID!required The ID of the company that the company location belongs to.
- Anchor to inputinput•Company
Location requiredInput! The fields to use to create the company location.
Was this section helpful?
Anchor to CompanyLocationCreatePayload returnsCompanyLocationCreatePayload returns
- Anchor to companyLocationcompany•
Location The created company location.
- Anchor to userErrorsuser•
Errors [BusinessCustomer non-nullUser Error!]! The list of errors that occurred from executing the mutation.
Was this section helpful?
Mutation Reference
1mutation companyLocationCreate($companyId: ID!, $input: CompanyLocationInput!) {2 companyLocationCreate(companyId: $companyId, input: $input) {3 companyLocation {4 # CompanyLocation fields5 }6 userErrors {7 field8 message9 }10 }11}
Input
1{2 "companyId": "gid://shopify/<objectName>/10079785100",3 "input": {4 "billingAddress": {5 "address1": "<your-address1>",6 "address2": "<your-address2>",7 "city": "<your-city>",8 "countryCode": "",9 "firstName": "<your-firstName>",10 "lastName": "<your-lastName>",11 "phone": "<your-phone>",12 "recipient": "<your-recipient>",13 "zip": "<your-zip>",14 "zoneCode": "<your-zoneCode>"15 },16 "billingSameAsShipping": true,17 "buyerExperienceConfiguration": {18 "checkoutToDraft": true,19 "editableShippingAddress": true,20 "paymentTermsTemplateId": "gid://shopify/<objectName>/10079785100"21 },22 "externalId": "<your-externalId>",23 "locale": "<your-locale>",24 "name": "<your-name>",25 "note": "<your-note>",26 "phone": "<your-phone>",27 "shippingAddress": {28 "address1": "<your-address1>",29 "address2": "<your-address2>",30 "city": "<your-city>",31 "countryCode": "",32 "firstName": "<your-firstName>",33 "lastName": "<your-lastName>",34 "phone": "<your-phone>",35 "recipient": "<your-recipient>",36 "zip": "<your-zip>",37 "zoneCode": "<your-zoneCode>"38 },39 "taxExemptions": [40 ""41 ],42 "taxRegistrationId": "<your-taxRegistrationId>"43 }44}
{
"companyId": "gid://shopify/<objectName>/10079785100",
"input": {
"billingAddress": {
"address1": "<your-address1>",
"address2": "<your-address2>",
"city": "<your-city>",
"countryCode": "",
"firstName": "<your-firstName>",
"lastName": "<your-lastName>",
"phone": "<your-phone>",
"recipient": "<your-recipient>",
"zip": "<your-zip>",
"zoneCode": "<your-zoneCode>"
},
"billingSameAsShipping": true,
"buyerExperienceConfiguration": {
"checkoutToDraft": true,
"editableShippingAddress": true,
"paymentTermsTemplateId": "gid://shopify/<objectName>/10079785100"
},
"externalId": "<your-externalId>",
"locale": "<your-locale>",
"name": "<your-name>",
"note": "<your-note>",
"phone": "<your-phone>",
"shippingAddress": {
"address1": "<your-address1>",
"address2": "<your-address2>",
"city": "<your-city>",
"countryCode": "",
"firstName": "<your-firstName>",
"lastName": "<your-lastName>",
"phone": "<your-phone>",
"recipient": "<your-recipient>",
"zip": "<your-zip>",
"zoneCode": "<your-zoneCode>"
},
"taxExemptions": [
""
],
"taxRegistrationId": "<your-taxRegistrationId>"
}
}
input CompanyLocationInput {
billingAddress: CompanyAddressInput
billingSameAsShipping: Boolean
buyerExperienceConfiguration: BuyerExperienceConfigurationInput
externalId: String
locale: String
name: String
note: String
phone: String
shippingAddress: CompanyAddressInput
taxExemptions: [TaxExemption!]
taxRegistrationId: String
}
input CompanyAddressInput {
address1: String
address2: String
city: String
countryCode: CountryCode
firstName: String
lastName: String
phone: String
recipient: String
zip: String
zoneCode: String
}
input BuyerExperienceConfigurationInput {
checkoutToDraft: Boolean
editableShippingAddress: Boolean
paymentTermsTemplateId: ID
}