For details on API authentication, see Authentication for FreeWheel Demand APIs.

Overview

This document is for demand-side parties interested in automating the process of retrieving, filtering, and updating buyer status on deals processed by FreeWheel. The FreeWheel Deal Sync API is designed to simplify trafficking of programmatic guaranteed (PG) deals and select private marketplace (PMP) deals for demand-side platforms.

Most TV programmatic deals are deal-ID based transactions, whose processes have traditionally been handled through offline processes. The FreeWheel Deal Sync API automates these processes by syncing deal-ID-based transaction settings between platforms to eliminate manual work and minimize human error.

In order to curate lists of deal IDs, the FreeWheel Deal Sync API offers the ability to pull and filter all deals associated with a seat. Demand-side platforms can filter programmatic deals by parameters like start date, as well as fetch PMP deals marked for pre-approval. Once retrieved, deal IDs can be associated with creatives in the Demand Creative Management API V1.

📘

Note

PMP pre-approval deals will only appear from publishers that enable the associated network function.

Deal Sync API Workflows

Retrieve All Deals

Publisher

  1. Ad ops creates a deal in MRM.
  • Assigns buyers to the deal (DSP/seat ID)
  • Assigns other transaction settings

FreeWheel

  1. Responds that the deal has been created.

DSP

  1. Requests a list of deals, passing the seat ID in the request, as well as any desired parameters.

FreeWheel

  1. Returns all deals targeted to a particular DSP that match the DSP's request parameters.

📘

Note

An active deal targeted to a particular DSP is a transaction with a Deal ID.

Update Buyer Status

DSP

  1. Requests list of all deals to review deals' buyerstatus.

FreeWheel

  1. Retrieves a list of all deals in the client network. Each deal contains a buyerstatus object with a status and comment from the buyer.

DSP

  1. Sends a PATCH request with the deal's ID. Includes a change to the status or comment.

FreeWheel

  1. Buyer status successfully updated.

Deal State Diagrams

Deal States for Sellers

Here are the states for a deal after it is created in MRM.

The following, except Pause, can only be updated by sellers.

StateDescriptionCan be changed to:
ActiveFreeWheel sends bid requests for this particular deal.
  • Inactive
InactiveA status of Inactive prevents a bid request from being sent for that deal.Any other state
PauseFreeWheel automatically changes the deal’s status to Pause if the deal has two weeks of inactivity.

Note: Sellers cannot change a deal to this state.
Inactive
ArchiveFreewheel specific status that represents a deal that is Inactive that can no longer be activated in the future and is no longer usable

**Deal cannot be updated once set to this status
Cannot be changed back to any other status
CompleteThe deal is complete and the flight date has ended.
  • Inactive
  • Active

Deal States for Buyers

Here are the states for a buyer for a deal synced without a status.

The following can only be updated by buyers.

StateDescription
ActiveThe deal is ready for bid requests.
InactiveThe Inactive status identifies deals that have been synced over to the DSP but are not ready to serve initially.

When a deal gets synced over, its status is empty rather than Inactive. FreeWheel assumes No Status refers to the deal's not being synced over. So the status needs to be changed from N/A- Empty to Inactive.

Buyers should only act on the Buyer status changes to communicate the deal's readiness.
PauseThe same as Inactive. However, a separate status is provided so that a seller can know the status.

Pause means the deal was acted upon by the buyer during the life of the campaign.

However, you can send a deal with an Inactive status.
CompleteThe deal is complete and the flight date has ended.

Deals Object

PropertyDescriptionTypeReturned in GET?
dealidThe deal IDstringYes
nameThe deal namestringYes
volumeImpression cap for the deal. If null, the deal has no impression cap.intOptional
flrThe applied floor price. (If the auction type is 3, this is the fixed price).decimalOptional
flrcurDeal currency using ISO-4217 alpha codesstringOptional
atAuction Type.

1. First price
2. Second price
3. Fixed price
integerYes
startdateStart date/time of this deal in UTC, ISO-8601datetime (ISO8601)Yes
enddateEnd date/time of this deal in UTC, ISO-8601datetime (ISO8601)Optional
updatedatIndicates the time in which any modifications to this deal are made.datetime (ISO8601)Yes
createdatIndicates the time in which the deal was created.datetime (ISO8601)Yes
guaranteedIndicates whether or not this is a PG deal.boolean (1 or 0)Yes
seatsThe list of seats targeted to the dealarray of stringsOptional
selleridUnique ID representing the end seller of the Deal ID

See also: sellers.json documentation
array of stringsYes
clearancelevelIndicates the seller creative clearance level setting for a particular deal ID.

1 = Restrictive. The creative must be approved to go live.
2 = Permissive. Creative approval is not required to go live.
integerYes
approvaltypeIndicates the seller approval type setting for a particular deal ID

0 = No approval is needed.
1 = Managed. FreeWheel manages creative approval on behalf of sellers.
2 = Client. Sellers manage creative approval themselves
integerYes
buyerstatusObject that contains information that can only be modified by the buyer

See the table below.
object
sellerstatusContains the status of the deal on the seller side.

This can only be modified by a seller.

This should refer to the existing statuses in the Programmatic Module.
enum
preingestpermissionsIndicates which type of pre-approval permission corresponds to a deal. Pre-ingestion is a back-end term for pre-approval.

1 = Required. Represents PG deals.
2 = Allowed. Represents PMP deals that the publisher allows for pre-approval.
3 = Not Allowed. Represents all other deals that are not PG or have not been enabled for a buyer to pre-approve their creatives.
4 = Not Available. Represents all other deals that are not part of the existing MRM prog mod workflow.
integerYes

Buyer Status Object

PropertyDescriptionTypeRequired?
statusA field within the buyerstatus object, it provides the status of the deal on the buy side.

This can only be modified by a buyer.
enum

Valid values:

  • INACTIVE
  • ACTIVE
  • PAUSE
  • COMPLETE
Yes
commentA field within the buyerstatus object, it allows a buyer to input their reasons for changing the buyer status.

This can only be modified by a buyer.
stringNo

Seller Status Object

PropertyDescriptionTypeRequired
statusA field within the sellerstatus object, it provides the status of the deal on the sell side.

This can only be modified by a seller.
enum

Valid values:

  • INACTIVE
  • ACTIVE
  • PAUSE
  • COMPLETE
Yes

🚧

Important

This schema may change as future enhancements are made to the current API version. FreeWheel highly recommends performing loose schema validations while integrating to the API.