Create sponsored brand auctions
Authentication
Topsort’s APIs are authenticated via bearer tokens. Requests must include an authorization header containing your private API key.
Don't have an API key yet? Learn how to generate one.
The header containing a private API key. Format this header as follows:
Authorization: Bearer <YOUR-API-KEY>
Request Body
The information describing what will be auctioned. Topsort will run an auction for each batched auction request, for which products’ bids will compete against each other.
object
Describes the intent of running a sponsored brand auction.
Exactly one of the following fields must be set:
products
category
object
Specifies the maximum number of auction winners that should be returned.
A category for the purpose of running an auction.
object
The category ID of the bids that will participate in an auction.
object
An array of product IDs that should participate in the auction.
An array of marketplace defined quality scores, each corresponding to the product ID with matching array index.
If given, these values will be combined with our internal quality scores to provide a score
that better represents the relevance of the participating products.
Note that the length of this array must be the same as the length of the ids
array and
that the values must be between 0 and 1.
Responses
The auction results. The list of winners will contain at most winners
entries per auction. It may contain fewer or no entries at all if there aren’t enough products with usable bids, that is, a bid amount greater than the reserve price and belonging to a campaign with enough remaining budget. Bids become unusable if campaign budget is exhausted, the bid is disqualified to preserve spend pacing, etc.
object
object
Array of winner objects in order from highest to lowest bid. It will be empty if there were no qualifying bids or if there was an error.
object
Where the product’s bid ranked in the auction. One-based, so the product with rank 1 won the auction. In an auction response, the winners array is sorted so rank will match the entry’s index.
The marketplace’s ID of the winning entity, depending on the target of the campaign.
An opaque Topsort ID to be used when this item is interacted with.
An optional title for the sponsored brand selected when creating the campaign.
Assets used to render the sponsored brand ad.
object
A vendor provided asset that the marketplace has to render. The asset will be served by Topsort’s CDN.
The role of the asset. It can be either logo
or image
.
The asset MIME type.
The size of the asset in bytes.
The asset width in pixels.
The asset height in pixels.
A boolean indicating whether this auction was resolved successfully.
HTTP status codes as registered with IANA.
object
A short string uniquely identifying the problem.
A link to a documentation page providing more information about the error.
Human-readable explanation of or details about the error. The string for a given error may change over time; code should not parse or dispatch based on particular values for this field.
Access token is missing or invalid