---
title: "Update template tracking"
method: PATCH
path: "/api/v1/templates/{id}/tracking"
tags: ["WhatsApp templates"]
---

# Update template tracking

`PATCH /api/v1/templates/{id}/tracking`

## Request

- Base URL: `https://www.useboom.ai`
- URL: `https://www.useboom.ai/api/v1/templates/{id}/tracking`
- Auth: HTTP bearer

Change the UTM tags a WhatsApp template adds to its URL buttons, e.g. `{ "id": "…", "tracking": { "utm": { "campaign": "black_friday" } } }`, or `{ "utm": false }` to stop tagging. Works on approved templates with no new review: tags are added when each message is sent. Tracking can only be added to a template that has not been sent for review yet; for an approved template without it, create a new one with `tracking`.

## Path parameters

- `id` string, required: Template id.

## Request body

- object
  - `tracking` object, required
    - `utm` union, required: UTM tags added to every URL button at send time. `false` = none. An object (even `{}`) turns them on; omitted fields default to `utm_source=boom`, `utm_medium=whatsapp`, and `utm_campaign` = the template name.
      - false
      - object
        - `source` string
        - `medium` string
        - `campaign` string, nullable
    - `clicks` boolean: Count each person's taps on URL buttons. The button opens through a short `useboom.ai/l/…` link that records the tap and forwards to your URL. Needs click tracking enabled for your organization. Can only be chosen when the template is created.

## Response `200`

Success

- object
  - `id` string, required: Template id.
  - `name` string, required: Template name (unique per WhatsApp account, i.e. across all its numbers).
  - `language` string, required: WhatsApp language code the template was created for, e.g. `es_MX`.
  - `category` 'UTILITY' | 'MARKETING' | 'AUTHENTICATION', required
  - `contentType` 'TEXT' | 'MEDIA' | 'QUICK_REPLY' | 'CALL_TO_ACTION' | 'CARD', required
  - `content` unknown, required
  - `variables` object, nullable, required: Example values for `{{1}}`-style placeholders.
  - `phoneNumbers` string[], required: WhatsApp numbers this template can be sent from: every number on the WhatsApp account it was created on.
  - `whatsappAccount` object, nullable, required: The WhatsApp account (WABA) the template belongs to. Only its numbers can send it. Null if that account is no longer connected.
    - `id` string, required: Meta's WhatsApp Business Account ID (WABA ID), as shown in Meta Business Manager.
    - `name` string, required: The account's name: the team's alias when one is set, otherwise what its numbers are called on WhatsApp.
    - `alias` string, nullable, required: The name the team gave this account in Boom (e.g. "Soporte"), or null. Accepted anywhere a WABA ID is, such as `whatsappAccountId` on templates_create.
    - `phoneNumbers` string[], required: Every active number on this account. Each one can send all of its templates; no number outside it can.
  - `status` 'DRAFT' | 'PENDING' | 'APPROVED' | 'REJECTED', required: DRAFT (not yet submitted), PENDING (in WhatsApp review, typically 24-48h), APPROVED, or REJECTED (see rejectionReason).
  - `rejectionReason` string, nullable, required
  - `tracking` object, nullable, required: Button tracking, or null for an untracked template. `content` shows the button URLs as you typed them; the tags are added when each message is sent.
    - `utm` object, nullable, required: Tags added to URL buttons at send time; null = none.
      - `source` string, required
      - `medium` string, required
      - `campaign` string, nullable, required
    - `clicks` boolean, required: Whether each person's taps on URL buttons are counted.
  - `createdAt` string, required: ISO 8601 timestamp.
  - `updatedAt` string, required: ISO 8601 timestamp.

## Other responses

- `400`: Validation failed or the request cannot proceed.
- `401`: Missing, malformed, or revoked API key.
- `404`: The resource does not exist in this organization.
- `409`: Conflicts with the current state (duplicates, wrong lifecycle state).
- `422`: The request is well-formed but semantically invalid.
- `429`: Rate limit exceeded — retry after `Retry-After`.
- `500`: Internal server error.
- `503`: Transient error — retry with a narrower request.

## Changes

- **2026-11-03** `7c7a773b12ce`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/useboom/apis/boom-api/changes/api/v1/templates/:id/tracking/patch.md)

---

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