For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
  • Overview
    • Introduction
    • Response Codes
  • API Reference
      • GETGet campaign
      • PUTUpdate campaign
      • DELDelete campaign
      • GETList campaigns
      • POSTCreate campaign
LogoLogo
API ReferenceCampaigns

Update campaign

||View as Markdown|
PUT
https://hublinks.io/rest/accounts/:account_id/campaigns/:campaign_id
PUT
/rest/accounts/:account_id/campaigns/:campaign_id
$curl -X PUT https://hublinks.io/rest/accounts/account_id/campaigns/campaign_id \
> -H "X-API-KEY: <apiKey>" \
> -H "Content-Type: application/json"
200Response
1{
2 "success": true,
3 "campaign": {
4 "name": "Test campaign 44",
5 "seats": [
6 "SEAT6a13e661ecc6a86e3fb7"
7 ],
8 "status": "RUN",
9 "schedule": {
10 "friday": [
11 true,
12 true,
13 true
14 ],
15 "monday": [
16 true,
17 true,
18 true
19 ],
20 "sunday": [
21 false,
22 true,
23 true
24 ],
25 "tuesday": [
26 true,
27 true,
28 true
29 ],
30 "saturday": [
31 false,
32 true,
33 true
34 ],
35 "thursday": [
36 true,
37 true,
38 true
39 ],
40 "wednesday": [
41 true,
42 true,
43 true
44 ]
45 },
46 "timezone": 180,
47 "account_id": "ACCO136ce10b5f8a7682efb3",
48 "created_at": 1756467767495,
49 "campaign_id": "campaign_ecf9db818d576d145e0f"
50 }
51}
Update fields on a campaign (ID & account_id are provided by path/context; not in body). **Request body fields (wrapped in `campaign` object):** - `name` (string, required) - Human-readable campaign name. - `account_id` (string, required) - Target account ID. - `status` (string, optional) - `DRAFT` | `RUN` | `PAUSE` | `DONE`. Defaults to `DRAFT`. - `seats` (array of strings, required) - Seat IDs to run this campaign. - `schedule` (object, required) - Day-of-week schedule. Each day key maps to `[enabled (bool), start_hour (int), end_hour (int)]`. - `timezone` (integer, optional) - UTC offset in minutes (e.g. `-300` = UTC-5). - `campaign_id` (string, optional) - Supply to create with a specific ID; omit to auto-generate.
Was this page helpful?
Previous

Get campaign

Next

Delete campaign

Built with

Update fields on a campaign (ID & account_id are provided by path/context; not in body).

Request body fields (wrapped in campaign object):

  • name (string, required) - Human-readable campaign name.
  • account_id (string, required) - Target account ID.
  • status (string, optional) - DRAFT | RUN | PAUSE | DONE. Defaults to DRAFT.
  • seats (array of strings, required) - Seat IDs to run this campaign.
  • schedule (object, required) - Day-of-week schedule. Each day key maps to [enabled (bool), start_hour (int), end_hour (int)].
  • timezone (integer, optional) - UTC offset in minutes (e.g. -300 = UTC-5).
  • campaign_id (string, optional) - Supply to create with a specific ID; omit to auto-generate.

Authentication

X-API-KEYstring
API Key authentication via header

Path parameters

account_idstringRequired
campaign_idstringRequired

Request

This endpoint expects an object.
campaignobjectRequired

Response

This endpoint returns an object.
successboolean
campaignobject