Map Inputs step allows mapping a PX API request to the buyer API using the Simple or Advanced view.
If this campaign has Ping/Post distribution type configured in Step 1, it consists of two blocks:
If this campaign has Direct Post distribution type configured in Step 1, it contains only one block - Map Your Post API Fields & Inputs.
The simple view is on by default. If you need to switch from advanced to a simple view, click Off for Advanced Code View. The simple view is rarely used because advanced view provides much more features for complex mapping.
If you switch Advanced view from On to Off and vice versa while editing, mappings will be lost.
To switch to an advanced view, click On for Advanced Code View. This view allows selecting the following format types according to buyer specification (click the format to open the corresponding document):
Click the appropriate format type to select it.
If Email post type is selected on Step 1, it is recommended to use XML format type for campaigns because it allows sending a well-formatted letter to the buyer.
Map Your Ping API Fields & Inputs
Map Your Ping API Fields & Inputs block consists of two parts:
- Template Editor with HTTP formatting as default, where all information from the buyer specification is entered;
- Mapping Panel on the right, which contains PX options that should be mapped to options from the buyer’s specification.
When any field is mapped, it is marked with a green tick:
Before You Start
To start mapping, you need the following:
- PX specification for a particular vertical (the list of all vertical specifications is available here).
- Buyer specification, containing a list of mandatory fields and their options, which should be mapped to appropriate PX fields.
If that is possible, it is recommended to map non-mandatory fields from the buyer specification, despite the fact they can be omitted. The more fields are mapped, the more data buyer’s API retrieves from a lead, and, consequently, the more valuable the lead becomes for the buyer.
The general flow of mapping fields between buyer and PX sides is the following:
- Map the names of the fields.
- Lead the fields mapped to a common format.
- Select Encoding Type for a particular field if it is required by a Buyer’s spec (None, URL or XML).
- Map the options of the fields.
- Enter a Test Value for the field mapped.
- Hardcode test values.
In theory, if a buyer’s specification contains a sample request to the buyer’s API, you can copy it to the Template Editor to simplify mapping process. However, sample requests rarely contain all the necessary fields. So it is recommended to map all the fields manually.
The mapping procedure varies according to the format type selected (HTTP, XML, JSON, SOAP). Let’s take a closer look at each of them, using the following as examples:
To undo the field mapping, delete the corresponding line from the Template Editor, and all mappings created for this field will be deleted as well.
As soon as all fields are mapped for ping request, it is recommended to go to Step 3 and then to Step 4 in order to make all possible testing, and only after that proceed with mapping Fields & Inputs for Post request. This flow allows avoiding random Lead sales because of sending the post request to the buyer.
Map Your Post API Fields & Inputs
There is a very convenient way to use the same fields and inputs that were mapped on the ping stage. To copy all the fields and inputs mapped from the ping to the post template editor, click Copy Ping Fields.
As soon as everything is copied, perform the following:
1. Delete irrelevant field mappings (if there are any, according to the иuyer specification).
2. Add and map the fields that are required in post request by the buyer specification. There are the following parameters that should be added to the post request:
- Contact data (first and last names, physical address, email address and phone numbers);
- Ping ID;
- Response ID (if necessary);
- Payout (if necessary).
Click Save to save all the settings or click Save and continue to save and proceed to the next step of API configuration.
Please sign in to leave a comment.