Uncategorized

CreateUpdateMember


The CreateUpdateMember API allows one to create or update member information in the Triton Loyalty database.

Parameters

  • member – A collection of member attributes in the XML format. See Remarks for the detailed description
  • token – An encrypted string constructed using the passed-in parameters and the partner-specific “shared secret” provided by Triton Loyalty. Unless requested differently by the partner, the MD5 hashing algorithm is used to produce the token. For the purpose of this call the following formula should be used: md5(SiteID + UserName + Email + Password + timestamp + shared secret).  SiteID, UserName, Email and Password are attributes of the member parameter (see Remarks for details).
  • partnerCode – Partner identifier issued by Triton Loyalty.
  • timestamp – Verification timestamp. UTC time of the client call. Must be the same value used to produce the token and in the following format: YYYYMMDDHHmmss.

How to call

This request is an http post. The contenttype attribute must be set to application/XML. The body of the post must be in the following format:

[xml]
<CreateUpdateMember  xmlns="http://www.tritonloyalty.com/ISubscriptions" xmlns:i="<a href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</a>">
<member xmlns:a="http://www.tritonloyalty.com/datacontract/MemberApiDO" xmlns:i="<a href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</a>">
<a:MemberID>0</a:MemberID>
<a:UserName>[email protected]</a:UserName>
<a:Password>xyz</a:Password>
<a:Email>[email protected]</a:Email>
<a:Gender>F</a:Gender>
<a:Zip>31562</a:Zip>
<a:SiteID>567</a:SiteID>
<a:TimeZoneCode>ET</a:TimeZoneCode>
<a:ReferredBy />
<a:HomeNetworkID />
<a:PersistCookie />
<a:HomePhone>770-123-4567</a:HomePhone>
<a:WorkPhone />
<a:FirstName>Bob</a:FirstName>
<a:LastName>Fireman</a:LastName>
<a:Address1>500 Chastain Blvd</a:Address1>
<a:Address2 />
<a:City>Kennesaw</a:City>
<a:State>GA</a:State>
<a:ScanCardNo>GA</a:ScanCardNo>
<a:EmailHTML>true</a:EmailHTML>
<a:NoEmail>false</a:NoEmail>
<a:DOB>1970-01-01</a:DOB>
<a:MemberOptIn1 />
<a:EmailOnly />
<a:EthnicityID />
<a:CompanyName />
<a:WorkAddress1 />
<a:WorkAddress2 />
<a:WorkCity />
<a:WorkState />
<a:WorkZip />
<a:MonthlyEmailOptIn />
<a:Country>US</a:Country>
<a:MyPoints />
<a:MobileNumber />
<a:ExMemberID />
<a:IPAddress />
<a:ListeningFrom />
<a:ThirdPartyAllowed />
<a:AffiliationID />
<a:Subscriptions xmlns:b="<a href="http://www.tritonloyalty.com/datacontract/SubscriptionInfo">http://www.tritonloyalty.com/datacontract/SubscriptionInfo</a>">
<b:SubscriptionInfo>
<b:SubscriptionID>1234</b:SubscriptionID>
<b:OptIn>true</b:OptIn>
</b:SubscriptionInfo>
<b:SubscriptionInfo>
<b:SubscriptionID>5678</b:SubscriptionID>
<b:OptIn>false</b:OptIn>
</b:SubscriptionInfo>
<b:SubscriptionInfo>
<b:SubscriptionID>9101112</b:SubscriptionID>
<b:OptIn>false</b:OptIn>
</b:SubscriptionInfo>
</a:Subscriptions>
</member>
<token>6B-2C-68-3B-56-BE-49-03-62-98-01-33-E6-5B-B5-66</token>
<partnerCode>TritonTest</partnerCode>
<timestamp>20100615161000</timestamp>
</CreateUpdateMember>
[/xml]

Note: Subscriptions XML is optional and can be excluded.

Return value

<SynchResponse xmlns=”http://schemas.datacontract.org/2004/07/ListenerAPI.DataObjects” xmlns:i=”http://www.w3.org/2001/XMLSchema-instance”>
<Status>FAILED</Status>
<MemberID i:nil=”true”/>
<Message>Call expired</Message>
<StatusCode>500</StatusCode>
</SynchResponse>

  • Status: “SUCCESS” or “FAILED”.
  • MemberID: will be filled if it was successfully processed. And this is the TL member id you may want to hold on for future use.
  • Message: error message.
  • StatusCode: 200, 400 or 500 (200 means no errors, it was successfully processed. 400 means client error, and 500 means system error).

Remarks

The member parameter has the following set of attributes. The attributes are listed in the order, in which they are expected to appear when the structure is posted to the API.

Values that are required or used in the generation of the token parameter are highlighted.

  • MemberID (Required) – Unique ID of the member in the TL database. If the value is set to 0, a new record will be created in the TL database, provided that other values in the object meet all validation requirements.
  • UserName (Required) – Also used for the token generation. Depending on the site setting, the value can be either user-generated or user’s email. See GetStationInfo API.
  • Password (Required) – Also used for the token generation.
  • Email (Required) – Also used for the token generation.
  • Gender
  • Zip
  • SiteID (Required) – Also used for the token generation. Unique ID for your Site in the TL database. Given by TL.
  • TimeZoneCode (Required) – Time Zone Code using one of the following values: ET, CT, PT
  • ReferredBy
  • HomeNetworkID
  • PersistCookie
  • HomePhone – Phone Number in the following format 999-999-9999
  • WorkPhone – Phone Number in the following format 999-999-9999
  • FirstName – Required, if last name is specified
  • LastName – Required, if first name is specified
  • Address1
  • Address2
  • City
  • State
  • ScanCardNo
  • EmailHTML – HTML Format in Email only
  • NoEmail – Indicates whether the member wants to receive communications from the TL program. Allowed value: “true” or “false”.
  • DOB – Members date of birth in the following format: yyyy-mm-dd.
  • MemberOptIn1
  • EmailOnly
  • EthnicityID
  • CompanyName
  • WorkAddress1
  • WorkAddress2
  • WorkCity
  • WorkState
  • WorkZip
  • MonthlyEmailOptIn
  • Country -Country using one of the following values: US, CA, AU, KY
  • MyPoints
  • MobileNumber – Phone Number in the following format 999-999-9999
  • ExMemberID – Unique ID of the member in the partner database.
  • IPAddress
  • ListeningFrom
  • ThirdPartyAllowed
  • AffiliationID
  • Subscriptions (optional). This allows a registration to include information about which subscriptions to opt-in / opt-out of.  Containing one or more SubscriptionInfo structures. Each SubscriptionInfo tag contains two sub-tags: SubscriptionID and OptIn. SubscriptionID simply contains the unique identifier for a subscription, while OptIn indicates whether or not to subscribe to that particular item.

Examples

For an generic example of this API call from PHP, please refer to UpdateMember

Uncategorized
Frankly Inc. Announces Results of Special Meeting of Shareholders to Consider Business Combination with Torque Esports Corp. and WinView, Inc.
Uncategorized
Mega Contest Update: $1,500 Spa Day for Mom Giveaway Starts Now!