For most placements, default codes (also called passback codes or fallback codes) can be set. These are used in cases when AdSpirit cannot deliver a campaign (for example, because all campaigns are excluded due to targeting).
Placement- General - Default Code
The default code can be used to:
- Display alternative content (such as ads from third-party providers)
- Add logic to remove content (such as hiding iframes)
- Return impressions to the publisher so they can fill them otherwise
Prevent counting of unfilled placements
In scenarios where the ad server does not fill an placement with campaigns and thus does not count views, discrepancies may occur compared to the numbers from the publisher (or higher-level ad servers). Since the publisher does not receive information that the placement is empty, they must assume that all impressions have been filled. To prevent this, the default code can be used to signal to the publisher that no fill has occurred here.
A typical sequence of such delivery is as follows:
- Page is loaded
- Publisher ad server is loaded
- Publisher ad server outputs AdSpirit placement code + counts impression ("AdSpirit shown")
- AdSpirit loads and searches for campaigns
- AdSpirit finds no campaigns and therefore outputs the default code
- Default code loads and can perform additional logic
Typical ways to return unfilled placements to the publisher are:
- Place a publisher-defined ad code. In the case of a return (Step 6), this publisher ad server will show a campaign from the publisher. In this case, the publisher will continue to count all impressions that went to AdSpirit (Step 3), but can subtract the impressions that occurred on their own publisher ad server (Step 6) from the previously counted impressions (Step 3).
- Place a publisher-defined passback code. This signals to the publisher's ad server that no campaign was served by AdSpirit. The publisher's ad server can then correctly calculate the sold views (subtracting the return of impressions from Step 6 from the measured numbers in Step 3) and, on the other hand, serve an alternative campaign themselves.
```