Submit a Ticket My Tickets
Welcome
Login  Sign up

How to Post Leads to a Buyer's System

What Does It Mean To Post Leads To A Buyer In CAKE?


CAKE’s Lead Distribution platform allows you to collect personal lead data about a consumer (name, email etc.) and then distribute, or sell, the lead to a Buyer.


Leads can be purchased from 3rd party partners, such as an affiliate, or directly posted from your website.


Once a lead is in CAKE, you can take advantage of CAKE’s lead router to deliver the lead to a 3rd party Buyer or your internal CRM.


Although CAKE supports email delivery of leads, this article is focused on how to post a lead from CAKE to another platform.



How Do I Start Posting Leads To A Buyer?


For Buyers who want to receive leads to their system via a direct post, they must first provide instructions on how to integrate with their system. These instructions are typically referred to as a "posting document" or "API specs."


If your buyer wants to receive leads to their system via ping and post, click here for more details.


Note:

CAKE supports both HTTP POST and GET requests, as well as formatting those request in JSON or XML. It is important to confirm with your Buyer that their system can support one of these methods before attempting to integrate.



Where Do I Configure A Buyer's Posting Document?


To configure a Buyer’s posting document, you will navigate to the Delivery Method tab of the Buyer Contract card. 


To access this tab, follow these steps:


  1. Navigate to the Lead Gen Main Tab
  2. Navigate to the Contracts sub tab
  3. Search the name of the Buyer Contract
  4. Click on the Buyer Contract name to launch the card
  5. Click on the Delivery Method tab




How To Configure A Post URL


The Post URL is the endpoint that your Buyer has provided to you as the destination for the leads. The Post URL will be placed in the Post URL field.


To add a Post URL, follow these steps:


  1. Click On the Delivery Method tab of the Buyer Contract Card
  2. Type or copy/paste the Post URL into the Post URL field
  3. Click Save



Note:

Some Buyer systems may require specific credentials to access their system. If provided with this information, type or copy/paste the username and password into the fields below the Post URL and click save.



How To Map POST & GET Fields


The Post Fields section is where you will input the fields specified on the Buyer's posting document. 


To map a POST or GET field, follow these steps:


  1. Click Add under the Post Fields Tab
  2. Leave unchecked to map a POST field or tick the GET checkbox to map as a GET field
  3. Type or copy/paste the Buyer's field name into the Parameter field
  4. Choose the associated CAKE Vertical field name from the Field dropdown
  5. Click Update to save the mapping



Note:

When mapping GET fields, CAKE will automatically add a “?” to the end of the Post URL to properly format the query string.



How To Map JSON Or XML Formatted Fields


JSON and XML are common formats used in POST and GET requests. Again, the Buyer's posting document will specify when this format is needed.


To map fields in JSON or XML format, follow these steps:

  1. Click the Post Body tab
  2. Type or copy/paste the Buyer's JSON/XML into the open text box
  3. Click the Show Lead Tokens button
  4. Choose the associated CAKE Vertical field token from the Tokens list
  5. Type or copy/paste the token name between the start and end of the tag name
  6. Click Save



Note:

If the Buyer's posting document includes an example of an XML or JSON formatted request, you can copy and paste the entire example into the Post Body text box.



How To Map A Static Value


If the Buyer's system requires a static value to be passed with each lead, you do not need to map to a CAKE vertical field or use a CAKE token. Instead, you will need to hardcode the value into the mapping.


To map a static value on a POST or GET request, follow these steps:


  1. Type or copy/paste the Buyer's field name into the Parameter field
  2. Add a '=' to the end of the parameter name
  3. Add the static value to the end of the '='
  4. Click Update to save



To map a static value in JSON or XML, follow these steps:


  1. Type or copy/paste the Buyer's JSON/XML into the open text box
  2. Type or copy/paste the static value between the start and end of the tag name
  3. Click Save



How To Map List Values


If a Buyer expects the data to be sent differently to their system than how it was received in CAKE, you can use a List Type field to translate each expected value. This option is only available with List Type fields.


To Map List Values on a POST or GET request, follow these steps:


  1. Ensure the CAKE vertical field is using a List data type
  2. Click Add under the Post Fields Tab
  3. Leave unchecked to map a POST field or tick the GET checkbox to map as a GET field
  4. Type or copy/paste the Buyer's field name into the Parameter field
  5. Choose the associated CAKE Vertical field name from the Field dropdown
  6. Click Update to save the mapping
  7. Click the hyperlink on the CAKE Vertical Field you just mapped
  8. Type or copy/paste the Buyer's values across from each associated CAKE value
  9. Click Save



Note:

Any fields left blank in the Mapped Values wizard shown above will be passed to the buyer the same way they are collected in CAKE. AKA they will not be translated.



To Map List Values in a JSON or XML format, follow these steps:


  1. Ensure the CAKE vertical field is using a List data type
  2. Click Add under the Post Fields Tab
  3. Leave unchecked to map a POST field or tick the GET checkbox to map as a GET field
  4. Type or copy/paste the Buyer's field name into the Parameter field
  5. Choose the associated CAKE Vertical field name from the Field dropdown
  6. Click Update to save the mapping
  7. Click the hyperlink on the CAKE Vertical Field you just mapped
  8. Type or copy/paste the Buyer's values across from each associated CAKE value
  9. Click Save
  10. Navigate to the Post Body tab
  11. Type or copy/paste the Buyer's JSON/XML into the open text box
  12. Click the Show Lead Tokens button
  13. Choose the associated CAKE Vertical field token from the Tokens list
  14. Type or copy/paste the token name between the start and end of the tag name
  15. Click Save




How To Map A Buyer Response


Responses allow CAKE to interpret the various messages the Buyer's system will send back once a lead is submitted. At bare minimum, you will need to map the success response for the CAKE system to recognize a lead sale.


To map a buyer's system response, follow these steps:


  1. Click the Responses tab
  2. Type or copy/paste the unique response value into the Text field
  3. Choose the appropriate interpretation value from the Interpret As dropdown
  4. Click Update to save the mapping



Note:

Each text value that is added must be unique to that response type and always returned in that specific response message. For example, using the screenshot above, the value of "OK" should only be present in the Buyer's success response. If the value of "OK" is also present in a duplicate response, that mapping will create false positives in the number of lead sales.



How To Map Buyer Response Tokens


Some Buyer's systems have the ability to pass back dynamic values in the success response and CAKE can use Regular Expression to extract and report on these values when present in the response. Here are the three dynamic response tokens that can be mapped in CAKE:


Price Token: The Price Token allows the Buyer's system to determine a dynamic price per lead as opposed to assigning the predetermined price set in the Buyer Contract > Delivery Schedule.


Redirect URL Token: The Redirect URL Token allows the Buyer's system to send a unique landing page URL where they would like to redirect the user. This response token can only be used when the lead comes from a Host-n-Post Offer.


Lead ID Token: The Lead ID Token allows the Buyer's system to pass back its own unique lead ID for that record. This is similar to the Transaction ID on a 3rd Party Offer. CAKE will report this value in any of the breakout reports within the Master Buyer Report. The column to enable is titled "Buyer Lead ID"


To map any of the above response tokens, follow these steps:


  1. Click the Response Tokens tab
  2. Type or copy/paste the portions of the system's JSON/XML response where Price, Redirect URL, and/or Lead IDs are returned
  3. Type or copy/paste the regex token (.*?) between the start and end of the tag name
  4. Click Save



Note:

The syntax used in the image above are just examples. Every Buyer's system is different in their response.



You may also be interested in:


Did you find it helpful? Yes No

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