inventorySupplierUpdate Mutation
Description
Updates an existing supplier's information, including tax information, addresses, and contacts.
mutation inventorySupplierUpdate(
$supplierRef: ID!
$supplierUpdateInput: SupplierUpdateInput!
) {
inventorySupplierUpdate(
supplierRef: $supplierRef
supplierUpdateInput: $supplierUpdateInput
) {
_id
createdAt
modifiedAt
name
addresses {
_id
description
firstName
lastName
addressLine1
addressLine2
streetNumber
city
state
stateCode
postCode
alpha2
country
type
}
contacts {
firstName
lastName
email
telephone
organisation
}
taxInformation
}
}
Variables
{
"supplierRef": "214537fae9c87c7c0cd5ef84",
"supplierUpdateInput": {
"taxInformation": "taxInformation",
"addresses": [
{
"description": "A description",
"addressLine1": "addressLine1",
"addressLine2": "addressLine2",
"streetNumber": 42,
"city": "Montreal",
"state": "Quebec",
"postCode": "postCode",
"alpha2": "alpha2",
"country": "Canada",
"stateCode": "stateCode",
"type": "type",
"geoLoc": {
"type": "type",
"coordinates": [
30.7
]
}
}
],
"contacts": [
{
"firstName": "John",
"lastName": "Doe",
"email": "email@example.com",
"telephone": "telephone",
"organisation": "organisation",
"notes": "notes"
}
]
}
}
Response
{
"inventorySupplierUpdate": {
"_id": "75166c22d2ef1a58df82948e",
"createdAt": 1706465555224,
"modifiedAt": 1756495213031,
"name": "example",
"addresses": [
{
"_id": "f82fdacd069a9fb67d95c4ef",
"description": "example",
"firstName": "example",
"lastName": "example",
"addressLine1": "example",
"addressLine2": "example",
"streetNumber": 42,
"city": "example",
"state": "example",
"stateCode": "example",
"postCode": "example",
"alpha2": "example",
"country": "example",
"type": "example"
}
],
"contacts": [
{
"firstName": "example",
"lastName": "example",
"email": "email@example.com",
"telephone": "example",
"organisation": "example"
}
],
"taxInformation": "example"
}
}
Arguments
| Name | Type | Description |
|---|---|---|
supplierRef | ID! | Reference ID of the supplier to update. |
supplierUpdateInput | SupplierUpdateInput! | Updated supplier information including tax information, addresses, and contacts. |