One to One

Description

The one to one interface is used to trigger direct single deliveries to single recipients. **Resource Location** .../interface/common/one2OneCreate.php Base URL https://response.pure360.com/ Custom Version http://{~customDomain~} **HTTP Method** POST | GET

Data Parameters

key value usage
userName
"test.sys"
API login username
password
"password123"
API login password
message_SYS_dataPolicy
"discard"
Retention policy for the message ("discard" for One to Ones)
message_contentType
"EMAIL"
  "SMS"
The One to One interface needs to know this to determine what form of validation to perform on the recipient's details (email or mobile validation) and which person record to retrieve.
toAddress
"test@test.com"
Recipient email address or mobile number.
message_messageName
"August_Deals"
The name of an existing message in the system to use for this one2one delivery, used by the process and not stored on the one2one entity.
The following are used if the message_messageName is not supplied. The message will ONLY be used for this delivery and will NOT be stored on the platform. It is used by the process and not the entity.
message_bodyPlain
or
message_bodyPlain_base64
"Header
---------
Email to {~first_name~}" or "base64 encoded version of the same string of text if specified"
Content to place in the PLAIN part of the message
message_bodyHtml
or
message_bodyHtml_base64
<h1>Header</h1><br />
Email to {~first_name~} or "base64 encoded version of the same string of html if specified"
Content to place in the HTML part of the message
message_bodySms
or
message_bodySms_base64
"Text to {~first_name~}"

or
base64 encoded version of the same string of text if specified
Content to place in the body part of the message
message_subject
“April Deals"
The subject line to appear in the message sent. Note that the subject line will be converted into the character set of the message on sending.
message_templateName
"email-msg-default_centered"
The name of the template into which the body content will be placed. The custom templates must have been already added to the platform for usage. To get a new template added contact either the customer success manager for the account, or the pure360 support team for more information
If omitted : Default is used
Please see EMAIL FACADE or SMS FACADE for more details
message_languageCode
"en_GB.ISO8859-15"
Language code for this message.
If omitted: Profile default language code used for this message.
message_trackHtmlInd
"Y"
Indicates whether to enable tracking of links within the html body, this will feedback these events into the platform one to one reports.
If omitted : Will default to "Y"
message_trackPlainInd
"Y"
Indicates whether to enable tracking of links within the plain text body, this will feedback these events into the platform one 2 one reports.
If omitted : Will default to "N"
multipartInd (SMS Only)
"Y"
Indicates whether the SMS being sent is a single message or spread over multiple messages (exceeding 160 characters).
If omitted : Defaults to "N"
deliveryDtTm
"12/09/2014 10:22:05"
The datetime that this delivery will be sent out (dd/mm/yyyy hh:mm:ss)
customData[fieldname]
"customData[first_name] = bob"
Populate merge fields within the content of the message (i.e. customData[firstname]=value)
attachmentName
"exampleAttachment"
Name of the attachment to add to the one to one send (a reference name - not the path)
attachment
[BASE 64 STRING]
The file itself encoded as a base64 string
json
true
Sets the return type from an OK string, to a JSON containing the response. If the "status" key has an "OK" value a sibling key, "bus_entity_campaign_one2one_key", will accompany this containing the delivery details (see below for details)

Response

Type code content : string
Success 200
"OK"
If json boolean provided in the request
{
    "bus_entity_campaign_one2one_key":    
    {
        "deliveryReportId": 6265599,
        "deliveryId": 6263800,
        "beanName": "bus_entity_campaign_one2one"
    },
    "status":"OK"
 }
Error 200
"Error : Error Message"
If json boolean provided in the request
{
    "status": "Error : Error Message\n"
}
**Example - Curl - Sending a One 2 One**
curl --data "userName=Test.sys&password=123456&toAddress=test@pure360.com&message_messageName=August_2014_deals&message_trackHtmlInd=Y&message_trackPlainInd=Y&deliveryDtTm=01/10/2014 00:01:02&customData[first_name]=bob" 'http://paint.pure360.com/interface/common/one2OneCreate.php'
This CURL request uses the system login (API login) Test.sys and the password for this, it sends the message called "August_2014_deals" to the address “[test@pure360.com](mailto:test@pure360.com)” with the tracking enabled for this message. It is scheduled to be sent on the 1st of october 2014 at 1 minute 2 seconds past midnight.