Skip to main content
Programmatic equivalent of the brand’s Locations page in the dashboard (the list, and its add and edit forms). The page and the API write through the same service, so a location saved on one reads back on the other. A brand location is a place that belongs to the brand itself: its head office, a production site, a store it runs. Retailers that stock the brand are not its locations.

When to use

  • The brand has no locations recorded yet, or is missing some.
  • An address has changed, or a location has closed.
  • The brand’s headquarters has moved.

Auth

X-API-Key header or OAuth token. Reading needs any member of the organization that owns the brand (or any API key of it). Writing needs an OWNER, MANAGER or EDITOR (or an API key with the EDITOR role or above): a read-only key gets 403. A brand of an organization the caller does not belong to is 404.

Flow

  • GET .../locations — every location, headquarters first: id, name, address, city, state_province, postal_code, country, is_headquarters, created, modified.
  • POST .../locations — add a location. name, address, city, postal_code and country are required and may not be empty; state_province and is_headquarters are optional. Marking it the headquarters clears the flag on the previous one. Returns 201.
  • PATCH .../locations/{id} — send only the fields you are changing. null, or an empty required field, is 422.
  • DELETE .../locations/{id} — delete the location (204).

Verify

  1. GET .../locations again and confirm each location you added or changed reads back with the address you intended, and at most one is the headquarters.
  2. Confirm no location you did not mean to touch changed or disappeared.