Working with Contacts

Starting with the May 2016 release, POST operations have been added for working with contacts.

These operations include:

Resetting the Password of a Contact

Use the POST method with the following syntax to reset a contact's password:

https://your_site_interface/services/rest/connect/version/contacts/contact_id/resetPassword

Request URI example

https://mysite.example.com/services/rest/connect/v1.4/contacts/1/resetPassword

Response example

The status 200 OK is returned, indicating that the password was reset. The contact has to create a new password at the next login.

Sending a Mailing to a Contact

You can send transactional mailing to a contact at a scheduled time using the REST API.

Use the POST method with the following syntax to send a mailing:

https://your_site_interface/services/rest/connect/version/contacts/contact_id/sendMailing

The following table lists the request parameters.

Parameter Description

mailing

Required. ID of the mailing.

incident or opportunity

Incident or opportunity ID. You can't use both.

scheduledTime

Time when the mailing will be sent, in ISO-8601 format. If scheduledTime isn't specified, the mailing will be sent immediately.

Request URI example

https://mysite.example.com/services/rest/connect/v1.4/contacts/1/sendMailing

Request body example

{
"mailing": {"id": 123},
"incident": {"id": 12},
"scheduledTime": "2016-02-28T04:00:00Z"
}

Response example

The status 200 OK is returned, indicating that the mailing has been scheduled.

Executing a Marketing Campaign or Flow

You can start a marketing campaign or flow by providing an entry point and relevant details using the REST API.

Use the POST method with the following syntax to execute a marketing campaign or flow:

https://your_site_interface/services/rest/connect/version/contacts/contact_id/executeMarketingFlow

The following table lists the request parameters.

Parameter Description

campaign or flow

Campaign or flow ID. You can't use both.

entryPoint

Entry point to the flow.

Request URI example

https://mysite.example.com/services/rest/connect/v1.4/contacts/1/executeMarketingFlow

Request body example

{
"campaign": {"id": 123},
"entryPoint": "entry0"
}

Response example

The status 200 OK is returned, indicating that the marketing campaign has been executed.