---
title: "Update Tracking Setting"
description: "How to call Update Tracking Setting (PATCH /api/tracking-settings/{id}) in the Klaviyo REST API: authentication, parameters, request and response bodies, and an example request."
url: "https://developers.klaviyo.com/en/v2025-01-15/reference/update_tracking_setting"
revision: "2025-01-15"
latestUrl: "https://developers.klaviyo.com/en/reference/update_tracking_setting"
operationId: "update_tracking_setting"
method: "PATCH"
endpoint: "https://a.klaviyo.com/api/tracking-settings/{id}"
authentication: "privateKey"
scopes: ["tracking-settings:write"]
rateLimits: {"burst":"10/s","steady":"150/m"}
revisionHeader: {"name":"revision","required":true}
deprecated: false
related: ["https://developers.klaviyo.com/en/v2025-01-15/reference/tracking-settings/llms.txt","https://developers.klaviyo.com/en/v2025-01-15/reference/get_tracking_settings.md","https://developers.klaviyo.com/en/v2025-01-15/reference/get_tracking_setting.md"]
---

# Update Tracking Setting

> This is the Markdown version of https://developers.klaviyo.com/en/v2025-01-15/reference/update_tracking_setting

```http
PATCH https://a.klaviyo.com/api/tracking-settings/{id}
```

Update the tracking setting with the given account ID.

- Revision header: `revision: 2025-01-15` (required)
- Scopes: `tracking-settings:write`
- Rate limits: Burst: `10/s`, Steady: `150/m`

## Example request

```bash
curl --request PATCH \
     --url 'https://a.klaviyo.com/api/tracking-settings/id' \
     --header 'Authorization: Klaviyo-API-Key your-private-api-key' \
     --header 'accept: application/vnd.api+json' \
     --header 'revision: 2025-01-15' \
     --header 'content-type: application/vnd.api+json' \
     --data '{
  "data": {
    "type": "tracking-setting",
    "id": "string",
    "attributes": {}
  }
}'
```

## Path parameters

- `id` (string, required): The id of the tracking setting (account ID).

## Headers

- `revision` (string, required): API endpoint revision (format: YYYY-MM-DD[.suffix]) Default: `2025-01-15`

## Request body

Content type: `application/vnd.api+json` (required)

- `data` (object, required)
  - `type` (string, required): Allowed values: `tracking-setting`
  - `id` (string, required): The id of the tracking setting (account ID).
  - `attributes` (object, required)
    - `auto_add_parameters` (boolean, nullable): Whether tracking parameters are automatically added to campaigns and flows.
    - `utm_source` (object)
      - `flow` (oneOf, nullable): The value of the tracking parameter when applied to a flow. Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
      - `campaign` (oneOf, nullable): The value of the tracking parameter when applied to a campaign. Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
    - `utm_medium` (TrackingParamDTO): Same fields as the first TrackingParamDTO above.
    - `utm_campaign` (TrackingParamDTO): Same fields as the first TrackingParamDTO above.
    - `utm_id` (TrackingParamDTO): Same fields as the first TrackingParamDTO above.
    - `utm_term` (TrackingParamDTO): Same fields as the first TrackingParamDTO above.
    - `custom_parameters` (object[], nullable): List of custom tracking parameters.
      - `flow` (oneOf, nullable): The value of the tracking parameter when applied to a flow. Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
      - `campaign` (oneOf, nullable): The value of the tracking parameter when applied to a campaign. Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
      - `name` (string, required): The name of the custom tracking parameter

### Example request body

```json
{
  "data": {
    "type": "tracking-setting",
    "id": "string",
    "attributes": {}
  }
}
```

## Responses

### 200: Success

Content type: `application/vnd.api+json`

- `data` (object, required)
  - `type` (string, required): Allowed values: `tracking-setting`
  - `id` (string, required): The id of the tracking setting (account ID).
  - `attributes` (object, required)
    - `auto_add_parameters` (boolean, required): Whether tracking parameters are automatically added to campaigns and flows.
    - `utm_source` (object, required): Same fields as TrackingParamDTO in the request body above.
    - `utm_medium` (TrackingParamDTO, required): Same fields as TrackingParamDTO in the request body above.
    - `utm_campaign` (TrackingParamDTO): Same fields as TrackingParamDTO in the request body above.
    - `utm_id` (TrackingParamDTO): Same fields as TrackingParamDTO in the request body above.
    - `utm_term` (TrackingParamDTO): Same fields as TrackingParamDTO in the request body above.
    - `custom_parameters` (object[], nullable): Additional custom tracking parameters. Same fields as CustomTrackingParamDTO in the request body above.
  - `links` (object, required)
    - `self` (string<uri>, required)

#### Example response body

```json
{
  "data": {
    "type": "tracking-setting",
    "id": "string",
    "attributes": {
      "auto_add_parameters": true,
      "utm_source": {
        "flow": {
          "type": "dynamic",
          "value": "email_subject"
        },
        "campaign": {
          "type": "dynamic",
          "value": "campaign_id"
        }
      },
      "utm_medium": {
        "flow": {
          "type": "dynamic",
          "value": "email_subject"
        },
        "campaign": {
          "type": "dynamic",
          "value": "campaign_id"
        }
      },
      "utm_campaign": {
        "flow": {
          "type": "dynamic",
          "value": "email_subject"
        },
        "campaign": {
          "type": "dynamic",
          "value": "campaign_id"
        }
      },
      "utm_id": {
        "flow": {
          "type": "dynamic",
          "value": "email_subject"
        },
        "campaign": {
          "type": "dynamic",
          "value": "campaign_id"
        }
      },
      "utm_term": {
        "flow": {
          "type": "dynamic",
          "value": "email_subject"
        },
        "campaign": {
          "type": "dynamic",
          "value": "campaign_id"
        }
      },
      "custom_parameters": [
        {
          "flow": {
            "type": "dynamic",
            "value": "email_subject"
          },
          "campaign": {
            "type": "dynamic",
            "value": "campaign_id"
          },
          "name": "string"
        }
      ]
    },
    "links": {
      "self": "https://www.example.com"
    }
  }
}
```

### 4XX: Client Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```

### 5XX: Server Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```
