---
title: "Replace a template"
method: PUT
path: "/api/v1/templates/{id}"
tags: ["Templates"]
---

# Replace a template

`PUT /api/v1/templates/{id}`

## Request

- Base URL: `https://getscaleforge.com`
- URL: `https://getscaleforge.com/api/v1/templates/{id}`
- Auth: HTTP bearer

## Request body

- object
  - `name` string
  - `product` string
  - `objective` string
  - `status` string
  - `daily_budget` number
  - `audience_name` string
  - `age_min` integer
  - `age_max` integer
  - `genders` string
  - `bid_strategy` string
  - `start_bid` number
  - `bid_step` number
  - `bid_count` integer
  - `primary_text` string
  - `headline` string
  - `link_url` string, uri
  - `cta` string
  - `page_id` string
  - `pixel_id` string
  - `conversion_event` string
  - `budget_optimization` 'CBO' | 'ABO'
  - `naming_template` string
  - `url_tags` string
  - `include_bid_in_name` boolean
  - `geo_locations` string[]
  - `placements` string[]
  - `interests` object[]
  - `custom_audiences` string[]
  - `exclusions` object[]
  - `device_platforms` string[]
  - `languages` string[]
  - `publisher_platforms` string[]

## Response `200`

Template updated

- object
  - `data` object
    - `id` integer
    - `name` string
    - `product` string, nullable
    - `objective` string
    - `status` string
    - `daily_budget` number, nullable
    - `audience_name` string, nullable
    - `age_min` integer, nullable
    - `age_max` integer, nullable
    - `genders` string, nullable
    - `bid_strategy` string, nullable
    - `start_bid` number, nullable
    - `bid_step` number, nullable
    - `bid_count` integer, nullable
    - `primary_text` string, nullable
    - `headline` string, nullable
    - `link_url` string, uri, nullable
    - `cta` string, nullable
    - `page_id` string, nullable
    - `pixel_id` string, nullable
    - `conversion_event` string, nullable
    - `geo_locations` string[]
    - `placements` string[]
    - `budget_optimization` 'CBO' | 'ABO', nullable
    - `naming_template` string, nullable
    - `times_used` integer
    - `created_at` string, date-time
    - `updated_at` string, date-time

## Other responses

- `422`: Validation failed

---

[API](https://skmtc.dev/getscaleforge/apis/scaleforge-api.md) · [All operations](https://skmtc.dev/getscaleforge/apis/scaleforge-api/llms.txt) · [OpenAPI document](https://skmtc.dev/getscaleforge/apis/scaleforge-api/revisions/ca382e62f404?raw)
