stable · guide · 0.1.0
Serve paid and House Ads
Define and request
Define an immutable Placement, then request an authenticated Ad Decision from the Project Backend. Send only fields allowed by the Placement's contextual Targeting Context schema.
An eligible paid Campaign wins by paced estimated eCPM. If no paid Campaign is eligible, MiniCenter tries the highest-priority reviewed House Ad. With neither candidate, the decision is null (no-fill).
Public adapters
Use the adapter that fits the publisher:
/ads/{projectClientId}/{placementCode}.json
/ads/{projectClientId}/{placementCode}/frame
/ads/{projectClientId}/{placementCode}/script.js
The JSON adapter returns the decision contract. The frame adapter isolates rendering, while the script adapter installs that frame. Responses are not a source of advertiser account or Project business data.
Pass contextual values under targeting[...]; every field and value must be present in the Placement schema. When an image-only Placement has exactly one Image Preset, the public adapters select it automatically.
The frame posts a versioned status message to its parent after the creative finishes loading:
{"source":"minicenter.ads","version":1,"type":"ad.rendered"}
The type is ad.no_fill when no eligible creative exists or an image cannot load. Hosts must validate the MiniCenter origin and the sending iframe window before acting on either message. The frame records a Viewable Impression only after at least half of the creative remains visible for one second.