Update Campaign
curl --request PUT \
--url https://api.example.com/api/v1/campaigns/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"messagesPerDay": 30,
"workingDays": [],
"workingHours": [
"<string>"
],
"active": true,
"increase_limit_gracefully": true,
"list_ids": [
"<string>"
],
"timezone": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/campaigns/{id}"
payload = {
"title": "<string>",
"messagesPerDay": 30,
"workingDays": [],
"workingHours": ["<string>"],
"active": True,
"increase_limit_gracefully": True,
"list_ids": ["<string>"],
"timezone": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
messagesPerDay: 30,
workingDays: [],
workingHours: ['<string>'],
active: true,
increase_limit_gracefully: true,
list_ids: ['<string>'],
timezone: '<string>'
})
};
fetch('https://api.example.com/api/v1/campaigns/{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://api.example.com/api/v1/campaigns/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'title' => '<string>',
'messagesPerDay' => 30,
'workingDays' => [
],
'workingHours' => [
'<string>'
],
'active' => true,
'increase_limit_gracefully' => true,
'list_ids' => [
'<string>'
],
'timezone' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/campaigns/{id}"
payload := strings.NewReader("{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.example.com/api/v1/campaigns/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/campaigns/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"status": "LAUNCHED",
"active": true,
"messagesPerDay": 123,
"workingDays": [
"MONDAY"
],
"workingHours": [
"<string>"
],
"account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sequence_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"increase_limit_gracefully": true,
"timezone": "<string>",
"lists": [],
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}Campaigns
Update Campaign
Update campaign schedule, title, operating hours, daily limits, audience lists, or toggle the campaign run state.
PUT
/
api
/
v1
/
campaigns
/
{id}
Update Campaign
curl --request PUT \
--url https://api.example.com/api/v1/campaigns/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"messagesPerDay": 30,
"workingDays": [],
"workingHours": [
"<string>"
],
"active": true,
"increase_limit_gracefully": true,
"list_ids": [
"<string>"
],
"timezone": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/campaigns/{id}"
payload = {
"title": "<string>",
"messagesPerDay": 30,
"workingDays": [],
"workingHours": ["<string>"],
"active": True,
"increase_limit_gracefully": True,
"list_ids": ["<string>"],
"timezone": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
messagesPerDay: 30,
workingDays: [],
workingHours: ['<string>'],
active: true,
increase_limit_gracefully: true,
list_ids: ['<string>'],
timezone: '<string>'
})
};
fetch('https://api.example.com/api/v1/campaigns/{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://api.example.com/api/v1/campaigns/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'title' => '<string>',
'messagesPerDay' => 30,
'workingDays' => [
],
'workingHours' => [
'<string>'
],
'active' => true,
'increase_limit_gracefully' => true,
'list_ids' => [
'<string>'
],
'timezone' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/campaigns/{id}"
payload := strings.NewReader("{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.example.com/api/v1/campaigns/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/campaigns/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": \"<string>\",\n \"messagesPerDay\": 30,\n \"workingDays\": [],\n \"workingHours\": [\n \"<string>\"\n ],\n \"active\": true,\n \"increase_limit_gracefully\": true,\n \"list_ids\": [\n \"<string>\"\n ],\n \"timezone\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"status": "LAUNCHED",
"active": true,
"messagesPerDay": 123,
"workingDays": [
"MONDAY"
],
"workingHours": [
"<string>"
],
"account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sequence_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"increase_limit_gracefully": true,
"timezone": "<string>",
"lists": [],
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}{
"status": 400,
"error": "Bad Request",
"message": "Invalid request parameters.",
"details": "<unknown>"
}Authorizations
Enter your API key: wave_live_<token>
Path Parameters
Body
application/json
Updated campaign title
Updated daily limit (maximum limit is 60)
Required range:
1 <= x <= 60Active working days
Available options:
MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY Operating hours [start, end] in 24-hour UTC format (e.g. ['09:00', '18:00'])
Set True to resume / False to pause campaign
Graceful warmup ramp flag
Updated target audience list UUIDs
Operating timezone in standard IANA format (e.g. 'Asia/Kolkata', 'America/New_York'). Working hours run according to 24-hour UTC format.
Response
Successful Response
Campaign ID
Campaign title
Available options:
CREATED, LAUNCHED, PENDING, COMPLETED, MESSAGING_COMPLETED Available options:
MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY Attached audience list UUIDs

