Partially update a site
Updates a site field by field. Only the fields present in the request are changed; the others keep their current values, so the display name can be changed without resending the domain and the other way round.
The validation rules described under Update a site apply to the fields that are sent.
Token credential sent in the Authorization header, in the form: Token <your-token>. Requires a staff (admin) account.
The unique identifier of the site.
The fields of a site to change. Only the fields present in the request are updated.
Display name of the site. Cannot be empty.
Domain name the site is served on, given as a bare host name without a scheme or a trailing path. Must be unique across all sites and cannot contain spaces or tabs.
The site was updated successfully.
A site registered on the installation — a domain name together with the display name it is known by.
Identifier of the site, assigned when it is registered.
Display name of the site.
Domain name the site is served on.
The request contains invalid or missing data — for example a missing or empty display name, a display name longer than 50 characters, a domain longer than 100 characters, a domain containing a space or a tab, or a domain that is already registered to another site.
Authentication credentials were not provided or are invalid.
The authenticated user does not have administrator privileges.
The requested site does not exist.
The domain was claimed by another request between the moment this request was checked and the moment it would have been saved, so it now belongs to another site (site_100). Nothing was written. A domain that is already taken when the request arrives is reported as a validation error on the domain field instead.
PATCH /api/v1/remote/1/sites/{id}/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 24
{
"name": "Example Store"
}{
"pk": 1,
"name": "Example Store",
"domain": "www.example.com"
}Last updated
Was this helpful?

