Create Campaign

Create Campaign (New)

Users can create campaigns using our API authentication token.

Request URL

https://campaigns.zoho.com/api/v2/createCampaign

Request Type: Post

Header: Content-Type = application/x-www-form-urlencoded

List of Parameters

Parameter

Data Type

Description

authtoken*
scope*

String
String

API Authentication Token
CampaignsAPI

resfmt

String

xml (or) json

campaignname*

String

A name to your campaign

from_email*

String

Email address

subject*

String

Subject line

content_url

String

A valid HTML URL for your campaign content

list_details*

JSON(UTF-8 encoded)

{listkey:[segment_ID,...],listkey:...} - encoded value (You can get list key and segment ID from getmailinglists API)

* - Mandatory Parameters

Sample Request:

XML/JSON

https://campaigns.zoho.com/api/v2/createCampaign?campaignname=providecampaignname&from_email=patricia@zoho.com&subject=providesubject& authtoken[APIAuthentication_Token]&resfmt=json&list_details=%7B34594177d382061b27dd314490758f5d%3A%5B4000000023018 %5D%2C34594177d382061b939770a6d682df24%3A%5B%5D%7D%0A

Sample Response:

Our API response will let you know of the following be it in the XML or JSON format.

XML Format:

<response> <message>Campaign created successfully</message> <campaignKey>[campaignkey]</campaignKey> <code>200</code> <uri>/api/v2/createCampaign</uri> </response> ​

JSON format:

{ "message": "Campaign created successfully", "campaignKey": "code": "200", "uri": "/api/v2/createCampaign" }

Possible error cases

Error code Description
500An internal error occured while processing your request.
1001"resfmt" pattern does not match.
1004Invalid URL for content import.
3001Campaign content cannot exceed 300000 characters.
6606No lists selected for this campaign.

If your error code is not listed above, click here.

Share this post : FacebookTwitter

Still can't find what you're looking for?

Write to us: support@zohocampaigns.com