Adserver API best practices
Ad Server API Overview
The Pentaleap Adserver API is used to request and receive ads from the Pentaleap Retail Media platform.
There are two variations of the API implementation based on your use case:
- Standard Use Case: Sourcing all campaigns directly from Pentaleap and API-synced demand sources (such as SKAI or Pacvue).
- 3rd Party Demand Use Case: Sourcing some or all demand from an existing third party or demand platform.
In both cases, the API implementation remains the same. However, the 3rd Party Demand use case requires the use of our [For 3rd Party Demand] Implement Warmup for Demand Source callsWarmup API call.
Implementation Types
Backend integration has the benefit of minimal, consistent network time between Client and Pentaleap adserver – app integration may add latency


Recommended ways to integrate the different components
Backend requests
Ad Request: Ensures low network latency with backends hosted in same regions.
Conversion Events: In the backend to keep data hidden and prevent tampering
Frontend Requests
Impressions: In the browser which is aware if an ad on the screen or not. Data in tracking URLs are encrypted.
Clicks: In the browser which is aware of click events. Data in tracking URLs are encrypted.
Best Practices
Accurate Metadata: Ensure that all metadata (e.g., Ad Unit ID, UserID, search query, and category information) is accurate and complete to enable precise targeting and tracking.
Timely API Calls: Make API calls as soon as the final list of products to be shown is known to ensure real-time ad delivery and relevance.
Verify Endpoints and DNS: For each environment, Pentaleap will provide a set of endpoints, DNS, publisher, and site IDs. Verify that you are calling the correct endpoints for each environment to avoid misrouting and ensure data integrity.



Most integrations send 40-100 products
This gives us more relevant ads and better ad performance

Ideal integration solves for cross-page boosting and better overlap
Batches of products can be split out in the backend or front-end in various ways


Sourcing (third party) demand in parallel to search requests reduces latency
Implementing timeouts on ad requests guarantees that impact on speed is minimal


Demand Sources & Ad Request Logic
Desired behavior. When relying solely on third-party sources for ad demand, it's beneficial to ensure that there's significant overlap between the products featured organically and those with bids from the demand source. This practice enhances the relevance of the displayed ads for the end user, leading to better click-through rates (CTR) for the brands and retailers involved.

Undesired behavior. It's advisable to refrain from inserting demand source products into organic listings to achieve overlap. Doing so can create an artificial scenario that may result in the forced promotion of irrelevant products, undermining the user experience.

Undesired behavior. Removing duplicates is also discouraged since it reduces the chance of achieving any overlap between organic and sponsored products. This limitation can decrease the opportunity for products to be sponsored, while simultaneously increasing the likelihood of promoting irrelevant items.
