Update the business profile
PATCH
/business
const url = 'https://example.com/business';const options = { method: 'PATCH', headers: { cookie: 'bottle.session_token=<bottle.session_token>', 'Content-Type': 'application/json' }, body: '{"name":"example","companyNumber":"example","registeredAddress":{"line1":"example","city":"example","postcode":"example"}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://example.com/business \ --header 'Content-Type: application/json' \ --cookie bottle.session_token=<bottle.session_token> \ --data '{ "name": "example", "companyNumber": "example", "registeredAddress": { "line1": "example", "city": "example", "postcode": "example" } }'Renames the business or sets its company particulars. A company number is eight digits, or two letters and six; send null for none.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
string
companyNumber
string | null
registeredAddress
object
line1
required
string
city
string | null
postcode
required
string
Examplegenerated
{ "name": "example", "companyNumber": "example", "registeredAddress": { "line1": "example", "city": "example", "postcode": "example" }}Responses
Section titled “Responses”The profile as it now stands
Media typeapplication/json
object
name
required
string
companyNumber
required
string | null
registeredAddress
required
object
line1
required
string
city
required
string | null
postcode
required
string
Example
{ "name": "Acme Gas", "companyNumber": "01234567", "registeredAddress": { "line1": "1 Yard Lane", "city": "Kingston upon Thames", "postcode": "KT1 1EU" }}Not signed in
Media typeapplication/json
object
error
required
string
message
required
string
Example
{ "error": "not_found", "message": "Customer not found"}Not a member, or without the permission this needs
Media typeapplication/json
object
error
required
string
message
required
string
Example
{ "error": "not_found", "message": "Customer not found"}Validation failed
Media typeapplication/json
object
error
required
string
message
required
string
issues
required
Array<object>
object
path
required
string
message
required
string
Example
{ "error": "validation", "issues": [ { "path": "email", "message": "Invalid email" } ]}