Update DM Template
curl --request PUT \
--url https://www.catchthegoodones.com/api/v2/dm-templates/{id}import requests
url = "https://www.catchthegoodones.com/api/v2/dm-templates/{id}"
response = requests.put(url)
print(response.text)const options = {method: 'PUT'};
fetch('https://www.catchthegoodones.com/api/v2/dm-templates/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://www.catchthegoodones.com/api/v2/dm-templates/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://www.catchthegoodones.com/api/v2/dm-templates/{id}"
req, _ := http.NewRequest("PUT", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://www.catchthegoodones.com/api/v2/dm-templates/{id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.catchthegoodones.com/api/v2/dm-templates/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
response = http.request(request)
puts response.read_body{
"template": {
"id": 1,
"name": "Updated intro",
"messageBody": "Hey! Thanks for following. Let me know if you have any questions.",
"createdAt": "2026-04-10T12:00:00.000Z",
"updatedAt": "2026-04-17T12:00:00.000Z"
}
}
{
"error": "Template not found"
}
{
"error": "You already have a template called 'Updated intro'"
}
DM Templates
Update DM Template
Update an existing DM template
PUT
/
api
/
v2
/
dm-templates
/
{id}
Update DM Template
curl --request PUT \
--url https://www.catchthegoodones.com/api/v2/dm-templates/{id}import requests
url = "https://www.catchthegoodones.com/api/v2/dm-templates/{id}"
response = requests.put(url)
print(response.text)const options = {method: 'PUT'};
fetch('https://www.catchthegoodones.com/api/v2/dm-templates/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://www.catchthegoodones.com/api/v2/dm-templates/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://www.catchthegoodones.com/api/v2/dm-templates/{id}"
req, _ := http.NewRequest("PUT", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://www.catchthegoodones.com/api/v2/dm-templates/{id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.catchthegoodones.com/api/v2/dm-templates/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
response = http.request(request)
puts response.read_body{
"template": {
"id": 1,
"name": "Updated intro",
"messageBody": "Hey! Thanks for following. Let me know if you have any questions.",
"createdAt": "2026-04-10T12:00:00.000Z",
"updatedAt": "2026-04-17T12:00:00.000Z"
}
}
{
"error": "Template not found"
}
{
"error": "You already have a template called 'Updated intro'"
}
Updates an existing DM template. Both fields are required.
Headers
| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer ctgo_your_api_key_here |
Content-Type | Yes | application/json |
Path parameters
| Parameter | Type | Description |
|---|---|---|
id | integer | The template ID |
Body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Template name (1-100 characters). Must be unique. |
messageBody | string | Yes | Message content (1-2000 characters) |
Example
curl -X PUT https://www.catchthegoodones.com/api/v2/dm-templates/1 \
-H "Authorization: Bearer ctgo_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{"name": "Updated intro", "messageBody": "Hey! Thanks for following. Let me know if you have any questions."}'
Response
{
"template": {
"id": 1,
"name": "Updated intro",
"messageBody": "Hey! Thanks for following. Let me know if you have any questions.",
"createdAt": "2026-04-10T12:00:00.000Z",
"updatedAt": "2026-04-17T12:00:00.000Z"
}
}
{
"error": "Template not found"
}
{
"error": "You already have a template called 'Updated intro'"
}
⌘I