---
title: "Get markets v2"
method: GET
path: "/v2/affiliate/get_markets"
tags: ["market"]
---

# Get markets v2

`GET /v2/affiliate/get_markets`

## Request

- Base URL: `https://cash.api.prophetx.co/partner`
- URL: `https://cash.api.prophetx.co/partner/v2/affiliate/get_markets`
- Auth: API key in header `Authorization`

get the list of markets. New fields added in v2 response:
- category_name: the name of the market's category
- sub_type: the sub-type of the market

## Query parameters

- `event_id` integer, required
- `get_all_market` boolean
- `market_type` 'moneyline' | 'spread' | 'total' | 'sup_moneyline'
- `market_types` string[]
- `min_liquidity` number

## Response `200`

OK

- AffiliateListAffiliateResponseV2
  - `event_id` integer
  - `markets` V2AffiliateMarketV2[]
    - `category_name` string
    - `display_name` string
    - `favourite` boolean
    - `group_name` string
    - `id` integer
    - `line` number
    - `name` string
    - `player_id` integer
    - `selections` ContractSelection[]
      - `adjusted_odds` number
      - `competitor_id` integer
      - `display_line` string
      - `display_name` string
      - `display_odds` string
      - `line` number
      - `line_id` string
      - `name` string
      - `odds` number
      - `outcome_id` integer
      - `stake` number
      - `updated_at` integer
      - `value` number
    - `sub_type` string
    - `type` 'moneyline' | 'spread' | 'total' | 'sup_moneyline': @deprecated

## Other responses

- `400`: Bad request
- `500`: Internal server error

---

[API](https://skmtc.dev/prophetx/apis/external-affiliate-api.md) - [All operations](https://skmtc.dev/prophetx/apis/external-affiliate-api/llms.txt) - [OpenAPI document](https://skmtc.dev/prophetx/apis/external-affiliate-api/revisions/d93f12f53af0?raw)
