Skip to main content
POST
/
campaigns
/
{id}
cURL
curl --request POST \
  --url https://api.wapikit.com/api/campaigns/{id} \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "<string>",
  "description": "<string>",
  "listIds": [
    "<string>"
  ],
  "templateMessageId": "<string>",
  "enableLinkTracking": true,
  "tags": [
    "<string>"
  ],
  "status": "Draft",
  "phoneNumber": "<string>",
  "templateComponentParameters": {
    "header": [
      {
        "nameOrIndex": "<string>",
        "label": "<string>",
        "parameterType": "static",
        "dynamicField": "<string>",
        "staticValue": "<string>",
        "example": "<string>",
        "placeholder": "<string>"
      }
    ],
    "body": [
      {
        "nameOrIndex": "<string>",
        "label": "<string>",
        "parameterType": "static",
        "dynamicField": "<string>",
        "staticValue": "<string>",
        "example": "<string>",
        "placeholder": "<string>"
      }
    ],
    "buttons": [
      {
        "nameOrIndex": "<string>",
        "label": "<string>",
        "parameterType": "static",
        "dynamicField": "<string>",
        "staticValue": "<string>",
        "example": "<string>",
        "placeholder": "<string>"
      }
    ],
    "catalogId": "<string>",
    "productRetailerId": "<string>",
    "productSections": [
      {
        "title": "<string>",
        "productItems": [
          {
            "productRetailerId": "<string>"
          }
        ]
      }
    ]
  },
  "scheduledAt": "2023-11-07T05:31:56Z"
}'
{
  "isUpdated": true
}

Path Parameters

id
string
required

The id of campaign to update

Body

application/json

updated campaign info

name
string
required
listIds
string[]
required
tags
string[]
required
description
string
templateMessageId
string
status
enum<string>
Available options:
Draft,
Scheduled,
Running,
Paused,
Cancelled,
Finished
phoneNumber
string
templateComponentParameters
object

Object representing template component parameters. It consists of separate arrays for header, body, and button parameters.

scheduledAt
string<date-time>

Response

returns updated campaign.

isUpdated
boolean
required