The BuyerBridge API allows partners to integrate BuyerBridge features into their own platforms for a seamless end-user experience. Because the BuyerBridge dashboard itself was designed around APIs any functionality seen in the dashboard can be replicated within another system through the BuyerBridge API.
More specifically, the reporting API allows partners to:
- Display high-level metrics for each account and platform within a specified date range
- Break down metrics by campaigns, ad sets and ads
- Filter campaigns, ad sets and ads by keywords
- Show the underlying ad sets in one or more campaigns
- Show the underly ads in one or more ad sets
Technical Setup:
Connecting to the API
The API uses a standard RESTful interface using standard HTTPS connections and a Bearer token within each header for authentication. To obtain a long-lived token, please speak with your partner manager or contact support*.
Once you’ve obtained a token the request syntax is simple:
curl 'https://api.buyerbridge.io/api/v1/users/current' \
-H 'authorization: Bearer YOUR_TOKEN'
For the endpoint above, you will receive the following response if your token is valid (simplified for this example):
{
"data": {
"id": 1234,
"name": "CarSpot",
"email": "info@carspot.com"
}
}
NOTE: API access requires additional contract provisions
Common Reporting Endpoints
The list below is by no means exhaustive but should provide a high-level understanding of reporting endpoints:
Get Account Platform Metrics
GET https://api.buyerbridge.io/api/v1/dealers/{dealer_id}/platforms/{platform_name}/metrics
Parameters:
- start_date - Example: 2022-10-19
- end_date - Example: 2022-10-20
Get Account Campaigns
GET https://api.buyerbridge.io/api/v1/dealers/{dealer_id}/platforms/{platform_name}/campaigns/get
Parameters:
- start_date - Date Formatted String, Example: 2022-10-19
- end_date - Date Formatted String, Example: 2022-10-20
- page_size - Integer, Example 100
- stats - Boolean, Set to true for stats
Get Account AdSets
GET https://api.buyerbridge.io/api/v1/dealers/{dealer_id}/platforms/{platform_name}/ad-sets/get
Parameters:
- start_date - Date Formatted String, Example: 2022-10-19
- end_date - Date Formatted String, Example: 2022-10-20
- page_size - Integer, Example 100
- stats - Boolean, Set to true for stats
Get Account Ads
GET https://api.buyerbridge.io/api/v1/dealers/{dealer_id}/platforms/{platform_name}/ads/get
Parameters:
- start_date - Date Formatted String, Example: 2022-10-19
- end_date - Date Formatted String, Example: 2022-10-20
- page_size - Integer, Example 100
- stats - Boolean, Set to true for stats
IMPORTANT: Facebook endpoints are currently in a different format but are being transitioned to the formats above for consistency