> ## Documentation Index
> Fetch the complete documentation index at: https://docs.4casters.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get average price

> Best and average prices per game in a league

Returns a truncated list of best and average prices for every game in a league. For each game and each market (moneyline / spread / total), the response includes:

* the **best price** (the price on the top resting offer);
* the **average price** you'd pay sweeping at least **\$500** of liquidity;
* the **maximum bet** that could be filled at the best price and the average price.

The per-market arrays (`awayMoneylines`, `homeMoneylines`, etc.) are stripped from each game; only the summary `odds` block remains.

<Note>
  Unlike most endpoints, this one returns the games at the **top level** (not under `data`).
</Note>

## Request

`GET /exchange/getOddsForAveragePrice`

<ParamField query="leagueRequested" type="string" required>
  League code (case-insensitive).
</ParamField>

<CodeGroup>
  ```bash curl theme={null}
  curl "https://api.4casters.io/exchange/getOddsForAveragePrice?leagueRequested=NBA" \
    -H "Authorization: Bearer YOUR_TOKEN"
  ```
</CodeGroup>

## Response

<ResponseField name="games" type="array">
  Each `game` is the standard [Game](/pages/rest/markets/get-games#response) shape with the following additional fields:

  <Expandable title="Per-game extras">
    <ResponseField name="matchedVolume" type="number" />

    <ResponseField name="mainHomeSpread" type="string" />

    <ResponseField name="mainAwaySpread" type="number" />

    <ResponseField name="mainTotal" type="string" />

    <ResponseField name="odds" type="object">
      Best / average prices and max bet sizes for moneyline, spread, and total markets.

      <Expandable title="odds">
        <ResponseField name="averageHomeMoneyline" type="integer" />

        <ResponseField name="bestHomeMoneyline" type="integer" />

        <ResponseField name="bestHomeMoneylineWithCommission" type="integer" />

        <ResponseField name="bestHomeMoneylinePriceLimit" type="integer">Max bet at the best home-moneyline price.</ResponseField>

        <ResponseField name="averageAwayMoneyline" type="integer" />

        <ResponseField name="bestAwayMoneyline" type="integer" />

        <ResponseField name="bestAwayMoneylineWithCommission" type="integer" />

        <ResponseField name="bestAwayMoneylinePriceLimit" type="integer" />

        <ResponseField name="averageHomeSpread" type="integer" />

        <ResponseField name="bestHomeSpread" type="integer" />

        <ResponseField name="bestHomeSpreadWithCommission" type="integer" />

        <ResponseField name="bestHomeSpreadPriceLimit" type="integer" />

        <ResponseField name="mainHomeSpread" type="string" />

        <ResponseField name="averageAwaySpread" type="integer" />

        <ResponseField name="bestAwaySpread" type="integer" />

        <ResponseField name="bestAwaySpreadWithCommission" type="integer" />

        <ResponseField name="bestAwaySpreadPriceLimit" type="integer" />

        <ResponseField name="mainAwaySpread" type="number" />

        <ResponseField name="averageOver" type="integer" />

        <ResponseField name="bestOver" type="integer" />

        <ResponseField name="bestOverWithCommission" type="integer" />

        <ResponseField name="bestOverPriceLimit" type="integer" />

        <ResponseField name="averageUnder" type="integer" />

        <ResponseField name="bestUnder" type="integer" />

        <ResponseField name="bestUnderWithCommission" type="integer" />

        <ResponseField name="bestUnderPriceLimit" type="integer" />

        <ResponseField name="mainTotal" type="string" />

        <ResponseField name="maxMoneyLineBet" type="integer">Max of `homeMoneylineMaxBet` and `awayMoneylineMaxBet`.</ResponseField>

        <ResponseField name="homeMoneylineMaxBet" type="integer" />

        <ResponseField name="awayMoneylineMaxBet" type="integer" />

        <ResponseField name="maxTotalBet" type="integer" />

        <ResponseField name="maxOverBet" type="integer" />

        <ResponseField name="maxUnderBet" type="integer" />

        <ResponseField name="maxSpreadBet" type="integer" />

        <ResponseField name="maxHomeSpreadBet" type="integer" />

        <ResponseField name="maxAwaySpreadBet" type="integer" />
      </Expandable>
    </ResponseField>
  </Expandable>
</ResponseField>


## OpenAPI

````yaml GET /exchange/getOddsForAveragePrice
openapi: 3.1.0
info:
  title: 4casters REST API
  version: 1.0.0
  description: >-
    Public REST API for the 4casters peer-to-peer betting exchange. Use this API
    to manage your account, query the orderbook and games, and place / edit /
    cancel orders.


    All responses (unless noted otherwise) are JSON envelopes of the form `{
    "data": ... }`.
  contact:
    name: 4casters
    url: https://4casters.io
servers:
  - url: https://api.4casters.io
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Authentication
    description: Login and account session management
  - name: User
    description: Read account info, bets, and orders
  - name: Orders
    description: Place, edit, look up, and cancel orders
  - name: Markets
    description: Browse leagues, games, participants, and orderbooks
  - name: Affiliate
    description: Affiliate / referral commission
paths:
  /exchange/getOddsForAveragePrice:
    get:
      tags:
        - Markets
      summary: Get average price
      description: >-
        Return a truncated list of best and average prices for every game in a
        league. For each game and each market (moneyline / spread / total), the
        response includes:


        - the best price (the price on the top resting offer);

        - the average price you'd pay sweeping at least $500 of liquidity;

        - the maximum bet that could be filled at the best price and the average
        price.


        The per-market arrays (`awayMoneylines`, `homeMoneylines`,
        `homeSpreads`, `awaySpreads`, `over`, `under`) are stripped from each
        game; only the summary `odds` block remains.
      parameters:
        - name: leagueRequested
          in: query
          required: true
          schema:
            type: string
          description: League code (case-insensitive).
      responses:
        '200':
          description: Game best/average prices
          content:
            application/json:
              schema:
                type: object
                properties:
                  games:
                    type: array
                    items:
                      $ref: '#/components/schemas/GameAveragePrice'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  schemas:
    GameAveragePrice:
      allOf:
        - $ref: '#/components/schemas/Game'
        - type: object
          properties:
            matchedVolume:
              type: number
            mainHomeSpread:
              type:
                - string
                - number
              nullable: true
            mainAwaySpread:
              type:
                - string
                - number
              nullable: true
            mainTotal:
              type:
                - string
                - number
              nullable: true
            odds:
              type: object
              description: >-
                Best/average prices and max bet sizes for moneyline, spread, and
                total markets.
              properties:
                averageHomeMoneyline:
                  type: integer
                  nullable: true
                bestHomeMoneyline:
                  type: integer
                  nullable: true
                bestHomeMoneylineWithCommission:
                  type: integer
                  nullable: true
                bestHomeMoneylinePriceLimit:
                  type: integer
                  nullable: true
                averageAwayMoneyline:
                  type: integer
                  nullable: true
                bestAwayMoneyline:
                  type: integer
                  nullable: true
                bestAwayMoneylineWithCommission:
                  type: integer
                  nullable: true
                bestAwayMoneylinePriceLimit:
                  type: integer
                  nullable: true
                averageHomeSpread:
                  type: integer
                  nullable: true
                bestHomeSpread:
                  type: integer
                  nullable: true
                bestHomeSpreadWithCommission:
                  type: integer
                  nullable: true
                bestHomeSpreadPriceLimit:
                  type: integer
                  nullable: true
                mainHomeSpread:
                  type:
                    - string
                    - number
                  nullable: true
                averageAwaySpread:
                  type: integer
                  nullable: true
                bestAwaySpread:
                  type: integer
                  nullable: true
                bestAwaySpreadWithCommission:
                  type: integer
                  nullable: true
                bestAwaySpreadPriceLimit:
                  type: integer
                  nullable: true
                mainAwaySpread:
                  type:
                    - string
                    - number
                  nullable: true
                averageOver:
                  type: integer
                  nullable: true
                bestOver:
                  type: integer
                  nullable: true
                bestOverWithCommission:
                  type: integer
                  nullable: true
                bestOverPriceLimit:
                  type: integer
                  nullable: true
                averageUnder:
                  type: integer
                  nullable: true
                bestUnder:
                  type: integer
                  nullable: true
                bestUnderWithCommission:
                  type: integer
                  nullable: true
                bestUnderPriceLimit:
                  type: integer
                  nullable: true
                mainTotal:
                  type:
                    - string
                    - number
                  nullable: true
                maxMoneyLineBet:
                  type: integer
                homeMoneylineMaxBet:
                  type: integer
                awayMoneylineMaxBet:
                  type: integer
                maxTotalBet:
                  type: integer
                maxOverBet:
                  type: integer
                maxUnderBet:
                  type: integer
                maxSpreadBet:
                  type: integer
                maxHomeSpreadBet:
                  type: integer
                maxAwaySpreadBet:
                  type: integer
    Game:
      type: object
      description: Game without orderbook data.
      properties:
        id:
          type: string
        parentGameID:
          type: string
          nullable: true
        cheapDataUID:
          type: string
          description: >-
            Stable cross-system identifier for the game (used for line
            correlation).
        league:
          type: string
        sport:
          type: string
        start:
          type: string
          format: date-time
        ended:
          type: boolean
        live:
          type: boolean
        featured:
          type: boolean
        eventName:
          type: string
          nullable: true
        tournamentName:
          type: string
          nullable: true
        periodName:
          type: string
          description: e.g. `Full Time`, `1H`, `Set 1`.
        isSpecials:
          type: boolean
          description: True for futures and other specials markets.
        participants:
          type: array
          items:
            $ref: '#/components/schemas/Participant'
    Participant:
      type: object
      properties:
        id:
          type: string
        longName:
          type: string
        shortName:
          type: string
        homeAway:
          type: string
          enum:
            - home
            - away
        mainPitcher:
          type: string
          nullable: true
        rotationNumber:
          type: string
          nullable: true
        futuresSide:
          type: string
          nullable: true
        score:
          type: number
          description: Final score; only present for ended games.
  responses:
    Unauthorized:
      description: Missing or invalid auth token
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Pass your auth token in the `Authorization` header. The `Bearer` prefix
        is optional; the server also accepts a signed `auth` cookie or a `token`
        field in the request body.

````