Skip to main content
Before you author a wholesale product on an ad-server source, you need to know what the source supports, which creative formats and publisher properties it can carry, and which ad units, placements or segments you can sell. V3 reads each of these without a tool of its own: three include values on get for the small facts of one source, and one search kind for the long, paged list of selectors. Every read on this page needs a source with a managed ad-server connection, such as Google Ad Manager or FreeWheel. Pass the source’s own sourceId, as search({ "kind": "inventory_source" }) returns it. You never pass an ad-server connection id. A read changes nothing. Browsing a selector does not create, import or reserve anything: it gives you the values a product’s inventory is written from.

Read the source’s capabilities, formats and properties

Call get with kind: "inventory_source", the source’s id and any of capabilities, creativeFormats and publisherProperties:
A get that names none of the three returns what it returned before. If the source has no managed ad-server connection, or the connection cannot answer, that include is left out of the result and listed in unavailableIncludes with its reason. The other includes you asked for are still returned. A source that is not yours is not found, as for any get.

capabilities

What the ad-server adapter declares. These are the adapter’s own facts, not AdCP’s, so the names are the adapter’s, in camelCase. A list the adapter does not state is empty.

creativeFormats

The creative formats the source can carry, as AdCP format declarations. A format is named by format_kind and params, and has no agent URL. The source’s older format list, which names formats by agent URL and id, is not served. To use a format in a product, send its format_option_id, format_kind and params back in formatOptions on save_wholesale_product, unchanged. Do not send display_name, dimensions, assetTypes or requirements: a save does not take them.

publisherProperties

The properties the source can sell, and the selectors the ad server has already decided are valid. The result has two lists, properties and selectors. A property uses AdCP’s Property names: publisher_domain, property_id, identifiers (a list of type and value) and tags. AdCP also requires property_type and name. The ad server does not always state them, so a property carries only what the source stated. The ad server’s display text for a property is label, kept beside the AdCP fields and read-only. It is not AdCP’s name. A selector uses AdCP’s PublisherPropertySelector: selection_type (all, by_id or by_tag), publisher_domain, property_ids and property_tags. It is the shape inventory.publisher_properties takes on save_wholesale_product, so send one back unchanged. Its label is the ad server’s own text and is read-only. Apostra returns these as stored and does not check them against the AdCP schema when you read them. The check happens when you save a product.

Browse the source’s selectors

Selectors are the ad units, placements, segments and other items the ad server declares. A list can run to thousands, so it is a search, not an include:
  • sourceId and filter.selectorType are required. A search without either is refused. Take selectorType from the selectorTypes that capabilities lists.
  • query narrows the list by name. filter.parentId lists the children of one selector.
  • filter.mediaType is display or video, and filter.environmentType is BROWSER or VIDEO_PLAYER. Both are optional. Any other value is refused with VALIDATION_ERROR.
  • limit is at most 100. When more rows match, the answer has nextCursor. Send it back as cursor with the same sourceId and filters. If the ad server’s cursor is longer than 2048 characters, it is not returned: the answer has nextCursorTooLong: true and truncated: true instead. Narrow the search with query, filter.parentId, filter.mediaType or filter.environmentType.
  • The kind is explicit-only. A search with no kind never reads selectors, and get does not read a selector.
Each row has the ad server’s own facts: