Offer Campaign APIs
Create Source Ping API
The API URL serves as the endpoint where the traffic source submits lead data. This URL must be installed and used by the source sending the data to ensure it’s received properly by Pingtree. Find detailed documentation here. Use Generate Specs feature to get the api specification for this endpoint.
POST
cURL
Overview
The Source Ping API is the first step in a two-call ping-post flow. It submits partial lead data to determine whether buyers are willing to purchase the lead and at what price — before any PII (personally identifiable information) is committed. If the ping is accepted, you receive atransaction_id and bid information, which you then use to complete the submission via the Source Post API.
Use ping-post when you want buyer intent confirmation before collecting or submitting full consumer data.
Endpoint
{source-unique-id} with the linkUniqueId for your source, found in your posting specification under the Ping API section.
Authentication
Include the ping-specific API token in theAuthorization header:
Request Parameters
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
source-unique-id | string | Yes | Link unique ID for this source-campaign pairing |
Body Parameters (JSON)
Ping requests typically include non-PII fields sufficient for buyer evaluation. Required fields are defined in your posting specification.| Parameter | Type | Required | Description |
|---|---|---|---|
state | string | Conditional | 2-letter state code (used for geo-targeting) |
zip_code | string | Conditional | 5-digit ZIP code |
age | integer | No | Consumer age (alternative to date_of_birth) |
sub1 – sub5 | string | No | Publisher sub-tracking parameters |
adv1 – adv5 | string | No | Advertiser sub-parameters |
utm_source | string | No | UTM source |
utm_medium | string | No | UTM medium |
transaction_id | string | No | Publisher-generated ID; auto-generated if omitted |
loan_amount, insurance_type, home_owner) are often included in pings as they affect buyer bid logic. Check your posting spec for the full list.
Example Request
Example Responses
Success — Ping Accepted
Success — Ping Rejected (no buyers)
Error — Missing Required Field
Error — Unauthorized
Status Codes
| HTTP Code | Lead Status | Description |
|---|---|---|
| 201 | ping_accept | At least one buyer bid on this lead; proceed to post |
| 201 | ping_reject | No buyers matched; do not post |
| 400 | missingField | Required field absent |
| 400 | invalidField | Field failed format validation |
| 400 | rejected | Campaign or source rule rejected the ping |
| 401 | rejected | Invalid or missing ping token |
| 405 | rejected | HTTP method not allowed |
| 500 | rejected | Internal server error |
Tips
- Ping before collecting PII: Submit only the non-identifying lead attributes during the ping. Only proceed to collect name, email, and phone if the ping returns
ping_accept. - Store the
transaction_id: This ID must be included in the subsequent Post API call to link the two steps together. amountfield: The bid amount returned in the ping response (data.amount) can be used to display personalized offer messaging to the consumer before they complete the form.buyerTcpa: Some campaigns return buyer-specific TCPA consent language in the ping response. Display this text to the consumer before they submit their full details in the post step.- Ping TTL: A ping acceptance has a limited validity window (typically a few minutes). If too much time passes before the post call, the lead may be rejected or re-evaluated.
- Do not post on rejection: If
leadStatusisping_reject, do not proceed with the post call. Instead, consider an alternative buyer path or inform the consumer that offers are unavailable.
Previous
Create Source Post APIThe API URL serves as the endpoint where the traffic source submits lead data. This URL must be installed and used by the source sending the data to ensure it’s received properly by Pingtree. [Find detailed documentation here](/documentation/campaign/source-single-view/Ping-+-Post-API-(CS,-MC,-MP)). Use [Generate Specs](/documentation/campaign/source-single-view/Generate-Specs-(CS,-MC,-MP)) feature to get the api specification for this endpoint.
Next
cURL