Update a Campaign.

Examples

curl -i -X PUT -H "Content-Type: application/json" -d '{"campaign":{"name":"Work", "kind":3, "email_content": "<p>Test</p>", "email_object": "Subject", "email_sender": "Sender name"}}' https://api.passdock.com/api/v1/campaigns/1?api_token=75778a65dfdae310a107d2ef0bbd3780

Supported Formats

json

Success Response:

200 Good Request
              
          

Errors

400 Bad Request
401 Unauthorized

Params

Param name Description
api_token
required

Your Passdock API key


Value: Must be String
id
required

Campaign ID


Value: Must be Fixnum
campaign
required

Object that contains List's informations


Value: Must be a Hash
campaign[name]
required

List's name


Value: Must be String
campaign[list_id]
optional

List ID if you want to send the campaign only to a subset of contacts.


Value: Must be String
campaign[email_content]
required

Only for email campaigns: HTML content of the email


Value: Must be String
campaign[email_object]
required

Only for email campaigns: email subject


Value: Must be String
campaign[email_sender]
required

Only for email campaigns: email sender name (not the email from address!)


Value: Must be String
campaign[sms_content]
required

Only for SMS campaigns: SMS text


Value: Must be String
campaign[email_sender]
required

Only for SMS campaigns: either a phone number (which must be previously authorized) or a string


Value: Must be String