---
title: "Update a location"
method: PATCH
path: "/v2/locations/{id}"
tags: ["Locations"]
---

# Update a location

`PATCH /v2/locations/{id}`

## Request

- Base URL: `https://developers.brandtrack.ai/api.brandtrack.fm`
- URL: `https://developers.brandtrack.ai/api.brandtrack.fm/v2/locations/{id}`
- Auth: API key in header `x-customer-api-key`
- TypeScript: <https://skmtc.dev/brandtrack/apis/brandtrack-api-documentation/docs/v2/locations/:id/patch.ts> (a function with typed inputs; its response is checked against the schema)

Only values provided in the request will be updated.

## Headers

- `x-customer-api-key` string

## Request body

- object
  - `name` string: Must not be greater than 100 characters.
  - `country` string: The <code>iso</code> of an existing record in the countries table. Must be 2 characters.
  - `city` string, nullable: Must not be greater than 100 characters.
  - `address` string, nullable: Must not be greater than 255 characters.
  - `zip_code` string, nullable: Must not be greater than 20 characters.
  - `phone_number` string, nullable: Must not be greater than 40 characters.
  - `email` string, nullable: Must be a valid email address. Must not be greater than 100 characters.
  - `manager` string, nullable: Must not be greater than 255 characters.
  - `additional_information` string, nullable: Must not be greater than 1024 characters.

## Response `200`

Success

- object
  - `data` object
    - `id` integer
    - `account_id` integer
    - `name` string
    - `country` string
    - `address` string
    - `phone_number` string
    - `email` string
    - `manager` string
    - `created_at` string
    - `timezone` string
    - `type` string
    - `city` string
    - `zip_code` string
    - `additional_information` string

## Other responses

- `404`: Wrong ID

---

[API](https://skmtc.dev/brandtrack/apis/brandtrack-api-documentation.md) - [All operations](https://skmtc.dev/brandtrack/apis/brandtrack-api-documentation/llms.txt) - [OpenAPI document](https://skmtc.dev/brandtrack/apis/brandtrack-api-documentation/revisions/a2c747489f3a?raw)
