# List Deals

List the Deals

Endpoint: GET /deals
Version: 2.0

## Query parameters:

  - `ids` (string)
    _

  - `export` (string)
    _

  - `deal_type` (string)
    Returns a list of deals that match the specified query

  - `q` (string)
    Returns a list of deals that match the specified query

  - `sort_by` (boolean)
    Returns a list of deals sorted by the specified parameter

  - `page_offset` (string)
    Returns a list of deals starting from the specified page offset

  - `page_limit` (integer)
    Returns a number of deals equal to the specified page limit

  - `currency_code` (string)
    Returns a list of deals with price attributes converted to such currency

  - `status` (boolean)
    Returns a list of deals that match the specified status

  - `owner.type` (string)
    Returns a list of deals that match the specified owner type
    Enum: "INTERNAL", "ORGANIZATION", "AGENCY", "ADVERTISER"

  - `strategy_id` (integer)
    Returns a list of deals that are currently targeted by the strategy with that id

  - `owner.advertiser_id` (integer)
    Returns a list of deals that are editable by users of the advertiser with that id

  - `owner.agency_id` (integer)
    Returns a list of deals that are editable by users of the agency with that id

  - `owner.organization_id` (integer, required)
    Returns a list of deals that are editable by users of the organization with that id

  - `permissions.advertiser_id` (integer)
    Returns a list of deals that are targetable by the advertiser with that id

## Header parameters:

  - `Authorization` (string, required)
    _

## Response 200 fields (application/json):

  - `data` (array)

  - `data.advertiser_id` (integer)
    Advertiser id is 0 for global deal

  - `data.bill_type` (string)
    Who will be billed for the deal
    Enum: "EXCHANGE", "NONE", "PUBLISHER"

  - `data.channels` (array)
    List of advertising channels associated with this deal

  - `data.channels.id` (integer)
    Channel ID

  - `data.channels.name` (string)
    Channel name

  - `data.created_on` (string)

  - `data.currency_code` (string)
    ISO 4217 3-character currency code

  - `data.deal_identifier` (string)
    ID used within a bid request to reference the deal

  - `data.deal_type` (string)
    deal_type is the type of deal. PG is for a Programmatic Guaranteed deal, and STANDARD is the only other value allowed
    Enum: "PG", "STANDARD"

  - `data.description` (string)
    Description of the deal

  - `data.end_datetime` (string)
    string / timestamp as full RFC 3339 date strings including timezone offsets: YYYY-MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS-##:##

  - `data.entity_type` (string)
    Enum: "deal"

  - `data.id` (integer)
    ID of the deal

  - `data.name` (string)
    Name of the deal

  - `data.owner` (object)
    Level of ownership for the deal (i.e. who can edit the deal) and the id of the ownership entity. for example, if the ownership level is set to ADVERTISER, anyone with access to such advertiser can edit this deal.

  - `data.owner.id` (integer)

  - `data.owner.type` (string)
    Enum: "ADVERTISER", "AGENCY", "INTERNAL", "ORGANIZATION"

  - `data.permissions` (object)
    List of entities that are allowed to target this deal. if a higher-level entity is included, then do not include any lower-level entity that is part of the included higher level entity. for example, if an organization X is listed in this parameter, then automatically all agencies and advertisers that are part of the organization X will be included and listing any such agencies and adevertisers part of organization X will cause a validation error.

  - `data.permissions.advertiser_ids` (array)

  - `data.permissions.agency_ids` (array)

  - `data.permissions.all_organizations` (boolean)

  - `data.permissions.organization_ids` (array)

  - `data.price` (object)

  - `data.price.currency_code` (string)
    ISO 4217 3-character currency code

  - `data.price.value` (string)
    Maximum is 9,999,999.9999

  - `data.price_method` (string)
    CPM is the only acceptable value for now
    Enum: "CPM"

  - `data.price_type` (string)
    The deal is a "FLOOR" price deal (bids must be above this floor, and will likely clear above this floor) or "FIXED" price deal (bids must be at this price or above, and will clear at the fixed price)
    Enum: "FIXED", "FLOOR"

  - `data.start_datetime` (string)
    string / timestamp as full RFC 3339 date strings including timezone offsets: YYYY-MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS-##:##

  - `data.status` (boolean)
    Whether the deal is active

  - `data.sub_supply_source_id` (integer,null)
    ID of the publisher if the supply_source_id is set to 83 (BidSwitch)

  - `data.supply_source_id` (integer)
    Exchange providing the deal

  - `data.supply_source` (object)
    Supply source details

  - `data.supply_source.id` (integer)
    Supply source ID

  - `data.supply_source.name` (string)
    Supply source name

  - `data.publisher` (object,null)
    Publisher details

  - `data.publisher.id` (integer)
    Publisher ID

  - `data.publisher.name` (string)
    Publisher name

  - `data.strategies_count` (integer)
    Number of strategies targeting this deal

  - `data.organization_id` (integer)
    Organization ID that owns this deal

  - `data.impressions` (integer,null)
    Number of impressions

  - `data.effective_status` (string)
    Current effective status of the deal
    Enum: "ready", "creating", "ssp_status_mismatch", "ssp_start_date_mismatch", "ssp_end_date_mismatch", "organization_contract_start_date_error", "organization_contract_end_date_error", "organization_inactive", "agency_inactive", "advertiser_inactive", "campaign_inactive", "campaign_start_date_error", "campaign_end_date_error", "campaign_pg_flag_error", "strategy_inactive", "strategy_start_date_error", "strategy_end_date_error", "strategy_pg_flag_error", "strategy_concept_inactive", "creative_inactive", "deal_status_inactive", "deal_start_date_error", "deal_end_date_error", "strategy_not_assigned"

  - `data.severity` (integer,null)
    Severity level

  - `data.deal_groups` (array)
    Deal groups associated with this deal

  - `data.deal_groups.id` (integer)
    Deal group ID

  - `data.deal_groups.name` (string)
    Deal group name

  - `data.updated_on` (string)

  - `meta` (object)

  - `meta.count` (integer)

  - `meta.offset` (integer)

  - `meta.status` (string)

  - `meta.total_count` (integer)


