Hi,
I am executing a companyCreate mutation using the Shopify GraphiQL App, however I get an error on path “input.companyLocation.billingAddress” which isn’t that descriptive: “Invalid input.”. Below is the query, variables and response, what could be the issue here?
Query:
mutation companyCreate($input: CompanyCreateInput!) {
companyCreate(input: $input) {
company {
id
}
userErrors {
code
field
message
}
}
}
Variables:
{
"input": {
"company": {
"customerSince": "2022-08-30",
"externalId": "",
"name": "Better Call Saul",
"note": "Speedy justice for you"
},
"companyContact": {
"email": "justiceforyou@bettercallsaul.com",
"firstName": "Saul",
"lastName": "Goodman",
"locale": "en_US",
"phone": "+15058425662",
"title": ""
},
"companyLocation": {
"billingAddress": {
"address1": "9800 Montgomery Boulevard",
"address2": "",
"city": "Albuquerque",
"countryCode": "US",
"firstName": "Saul",
"lastName": "Goodman",
"phone": "+15058425662",
"zip": "87111",
"zoneCode": "NM"
},
"billingSameAsShipping": true,
"buyerExperienceConfiguration": {
"checkoutToDraft": true
},
"externalId": "",
"locale": "en_US",
"name": "Saul Goodman",
"note": "",
"phone": "+15058425662",
"taxExemptions": [],
"taxRegistrationId": ""
}
}
}
Response:
{
"data": {
"companyCreate": {
"company": null,
"userErrors": [
{
"code": "INVALID_INPUT",
"field": [
"input",
"companyLocation",
"billingAddress"
],
"message": "Invalid input."
}
]
}
},
"extensions": {
"cost": {
"requestedQueryCost": 10,
"actualQueryCost": 10,
"throttleStatus": {
"maximumAvailable": 2000,
"currentlyAvailable": 1990,
"restoreRate": 100
}
}
}
}
