Submit a Ticket My Tickets
Welcome
Login  Sign up

ADDEDIT Buyer Contract Delivery Method API Version 1

ADDEDIT BuyerContractDeliveryMethod  API V1

Updated on 2015-10-01
Current Version: Version 1
Deprecated Version: NA
Requests Allowed: GET&SOAP

 

Summary:

Returns "Buyer Contract Delivery Method ### Created" or "Buyer Contract Delivery Method ### Updated"

 

Resource/WSDL Page:

http://<your_domain_here>/api/1/addedit.asmx?op=BuyerContractDeliveryMethod


Parameters

api_key
Required
Type: STRING
Max Length: 50 Char.
Must be a valid API key (existing and Not expired)
Example Values: Fo35NRAqvFLXoZxqB4aVMhh
buyer_contract_id
Required
Type: INTEGER
Max Length: N/A
Buyer Contract’s CAKE entity ID. Obtained via EXPORT BuyerContracts API
Pass 0 to create a new Buyer Contract.
Passing a value greater than 0 will edit the Buyer Contract with that ID.


delivery_method_type
Required
Type: ENUM
Max Length: N/A
Identifies whether you’re building the ping delivery method or the post delivery method.

Pass “ping” to create or edit the ping delivery method.
Pass “post” to create or edit the delivery method.
url
Required
Type: STRING
Max Length: 100 Char.


Your Buyer’s URL where you’ll be posting the lead to.
Must include http or https
email_from
Required
Type: STRING
Max Length:  80 Char.


Email address you’d like lead emails to appear to come from for this Buyer Contract.
Pass blank to skip.


timeout
Required
Type: INTEGER
Max Length: N/A


Number of milliseconds the buyer is given to respond before timing out on the ping/post attempt.
Pass -1 to clear value or set to NULL

username
Required
Type: STRING
Max Length: 100 Char.


Allows you to pass a username in the header instead of in the request.

password
Required
Type: STRING
Max Length: 100 Char.


Allows you to pass a password in the header instead of in the request.
xml
Required
Type: STRING
Max Length: N/A


XML string used to post the lead to your buyer. If post fields are used instead, this must be done in the UI
emails_add_edit_options
Required
Type: INTEGER
Max Length: N/A
Allows you to choose the function of what you’re doing with the emails using a comma-separated list.
Pass 0 to add the email to the delivery method.
Pass 1 to remove the email from the delivery method.
Pass 2 to replace the email.

If you are passing multiple emails, pass an option for each email comma-separated.

email_ids
Required
Type: INTEGER
Max Length: N/A
This allows you to specify the emails you’re targeting from those that are currently in the delivery method by using their ID’s.  You can use a comma-separated list to correspond with the list from emails_add_edit_options.
See: EXPORT BuyerContracts API

emails
Required
Type: STRING
Max Length: N/A


Allows you to specify email addresses you want to use in the delivery method. Use a comma-separated list corresponding with the options from emails_add_edit_options and email_ids.

response_text_add_edit_options
Required
Type: INTEGER
Max Length: N/A
Allows you to choose the function of what you’re doing with the response text and disposition mappings using a comma-separated list.

Pass 0 to add the response text to the delivery method.
Pass 1 to remove the response text from the delivery method.
Pass 2 to replace the response text.
response_ids
Required
Type: INTEGER
Max Length: N/A
Allows you to specify the response text you’re targeting from those that are currently in the delivery method by using their ID’s which you can get through the Buyer Contracts export.  You can use a comma-separated list here, as well to correspond with the list from response_text_add_edit_options.
Pass 0 to skip.
To get ID’s see: EXPORT BuyerContracts API
response_texts
Required
Type: STRING
Max Length: N/A


Allows you to specify response texts you want to use in the delivery method. Use a comma-separated list corresponding with the options from response_text_add_edit_options and response_ids.



response_disposition_ids
Required
Type: INTEGER
Max Length: N/A


Allows you to specify the response disposition you want the response text mapped to.
See: GET Response Dispositions API v1

xml_decode_response_tokens
Required
Type: ENUM
Max Length: N/A
Controls the option to say whether or not the buyer’s response needs to be XML decoded.
Pass “on” to turn on.
Pass “off” to turn off.
response_price_token
Required
Type: STRING
Max Length: N/A


Allows you to enter a token to capture the lead price from the Buyer’s response.
Example Values: price>(.*?)<price

response_redirect_url_token
Required
Type: STRING
Max Length: 100


Allows you to enter a token to capture the redirect URL from the Buyer’s response.
Example Values: redirect>(.*?)<redirect

response_lead_id_token
Required
Type: STRING
Max Length: N/A


Allows you to enter a token to capture the Buyer’s lead ID from the Buyer’s response.
Example Values: leadid>(.*?)<leadid

response_session_id_token
Required
Type: STRING
Max Length: N/A


Allows you to enter a token to capture the Buyer’s session ID from the Buyer’s ping response.
Example Values: sessionid>(.*?)<sessionid


**Note all optional parameters still need to be passed through in the actual call. These parameters do not need a value (therefore you can use a null value). 

 

Example Request

GET
https://demo-new.cakemarketing.com/api/1/addedit.asmx/BuyerContractDeliveryMethod?api_key=3YmDJeT3VHTFhDqAjr2OlQ&buyer_contract_id=1498&delivery_method_type=post&url=http://testdomain.com&email_from=&timeout=-1&username=&password=&xml= %3Cxml%3E%23xmltoken%23%3C%2Fxml%3E&emails_add_edit_options=0,0,0,0&email_ids=0,0,0,0&emails=test@test.com,test1@test.com,test2@test.com,test3@test.com&response_text_add_edit_options=0&response_ids=0&response_texts=result>SUCCESS<result&response_disposition_ids=1&xml_decode_response_tokens=off&response_price_token=price>(.*?)</price&response_redirect_url_token=&response_lead_id_token=&response_session_id_token= 

 

 

Sample XML Response:

<?xml version=”1.0”encoding=”utf-8”?>

<buyer_contract_copy_filters_addedit_response xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns="http://cakemarketing.com/api/1/">

<success>true</success>

<message>

Buyer Contract (####) Delivery Method Created Successfully (####)

</message>

<row_count>0</row_count>

</buyer_contract_copy_filters_addedit_response>


Example Error Messages:

Error Message
Likely Cause
Invalid API Key
API Key does not exist or is expired
Invalid Buyer ID
buyer_id is <0 or is >0, but doesn’t match an existing Buyer’s ID.
Invalid Buyer Contract ID
buyer_contract_id is <0 or is >0, but doesn’t match an existing employee contact in CAKE.
Invalid Account Status ID
account_status_id value is not in list of available status ID’s.
Buyer Contract Name Already Exists
buyer_contract_name contains a pre-existing value.
Missing Required Fields
The fields listed are required, but missing. All fields are required to be passed.


Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.