Update details of a specific customer identified by its uinque customer ID, and receive the updated details in return.
Body
Required
-
The first and the last name of a customer if the customer is a person.
-
A human-readable name or label for a customer, making it easily identifiable to users.
-
The organization number issued by authorities, like a VAT number, of the customer if the customer is a company.
-
An optional field for referencing the customer with an ID from an external system, like an ERP or invoicing system.
Maximum length is
100. -
A flag variable indicating whether the customer is also a supplier (true) or not (false).
-
Addresses for the customer.
-
Email addresses for the customer.
-
A phone number for contacting the customer.
-
A mobile phone number for contacting the customer.
Maximum length is
25. -
A free-text note about the customer.
Maximum length is
10000.
curl \
--request PATCH 'https://rest.api.24sevenoffice.com/v1/customers/{customerId}' \
--header "Content-Type: application/json" \
--header "Authorization: string" \
--data '{
"person": {
"firstName": "John",
"lastName": "Doe"
},
"name": "ABC Corporation",
"organizationNumber": "123456789",
"externalReference": "EXT-12345",
"isSupplier": false,
"address": {
"visit": {
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"postal": {
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"billing": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"delivery": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
}
},
"email": {
"contact": "contact@example.com",
"billing": "billing@example.com"
},
"phone": "+47-12345678",
"mobilePhone": "+47-98765432",
"note": "Prefers to be contacted by email."
}'
# Headers
Authorization: string
# Payload
{
"person": {
"firstName": "John",
"lastName": "Doe"
},
"name": "ABC Corporation",
"organizationNumber": "123456789",
"externalReference": "EXT-12345",
"isSupplier": false,
"address": {
"visit": {
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"postal": {
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"billing": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"delivery": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
}
},
"email": {
"contact": "contact@example.com",
"billing": "billing@example.com"
},
"phone": "+47-12345678",
"mobilePhone": "+47-98765432",
"note": "Prefers to be contacted by email."
}
# Headers
Access-Control-Allow-Origin: string
Access-Control-Allow-Credentials: string
X-Trace-Id: string
# Payload
{
"id": 12345,
"name": "ABC Corporation",
"externalReference": "EXT-12345",
"pricelistId": 1,
"person": {
"firstName": "John",
"lastName": "Doe"
},
"isCompany": true,
"isSupplier": false,
"organizationNumber": "123456789",
"address": {
"visit": {
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"postal": {
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"billing": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
},
"delivery": {
"name": "ABC Corporation",
"countryCode": "NO",
"street": "Hovedgata 1",
"postalCode": "0123",
"postalArea": "Fornebu",
"countrySubdivision": "Viken"
}
},
"email": {
"contact": "contact@example.com",
"billing": "billing@example.com"
},
"phone": "+47-12345678",
"mobilePhone": "+47-98765432",
"note": "Prefers to be contacted by email.",
"createdAt": "2022-01-01 18:00:00.000Z",
"modifiedAt": "2023-12-31 18:00:00.000Z"
}