> ## 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 matched bets

> List bets that are matched but not yet graded

Returns all of the caller's bets that have been **matched but not yet graded** — i.e. open positions on games that are not yet settled.

## Request

`GET /user/getMatchedBets`

Takes no parameters.

<CodeGroup>
  ```bash curl theme={null}
  curl https://api.4casters.io/user/getMatchedBets \
    -H "Authorization: Bearer YOUR_TOKEN"
  ```
</CodeGroup>

## Response

<ResponseField name="data.matchedBets" type="array">
  Array of matched bets, sorted ascending by game start time.

  <Expandable title="MatchedBet">
    <ResponseField name="id" type="string">Bet id.</ResponseField>
    <ResponseField name="txID" type="string">Transaction id of the fill.</ResponseField>
    <ResponseField name="type" type="string">`moneyline`, `spread`, `total`, or `moneyline1x2`.</ResponseField>
    <ResponseField name="bet" type="number">Original bet size.</ResponseField>
    <ResponseField name="odds" type="integer">American odds at fill time.</ResponseField>
    <ResponseField name="spread" type="number">Present for `spread`.</ResponseField>
    <ResponseField name="total" type="number">Present for `total`.</ResponseField>
    <ResponseField name="OU" type="string">`over` or `under`. Present for `total`.</ResponseField>
    <ResponseField name="participantID" type="string">Present for `moneyline` and `spread`.</ResponseField>
    <ResponseField name="market" type="string">Present for `moneyline1x2`.</ResponseField>
    <ResponseField name="side" type="string">For `moneyline1x2` — `yes` or `no`.</ResponseField>
    <ResponseField name="userReference" type="string">Optional client-defined identifier passed at place time.</ResponseField>
    <ResponseField name="createdAt" type="string">ISO 8601 timestamp.</ResponseField>
    <ResponseField name="matchedTime" type="string">ISO 8601 timestamp the fill occurred.</ResponseField>
    <ResponseField name="origin" type="string">`offer` (you posted, taker hit you) or `wager` (you took resting liquidity).</ResponseField>
    <ResponseField name="risk" type="string">Risk on the matched portion (string-formatted, 2 decimals).</ResponseField>
    <ResponseField name="win" type="string">Win amount net of commission.</ResponseField>
    <ResponseField name="fee" type="string">Commission charged on the matched portion.</ResponseField>
    <ResponseField name="graded" type="boolean">Always `false` here.</ResponseField>
    <ResponseField name="closed" type="boolean">Whether the bet has been closed by an admin action.</ResponseField>
    <ResponseField name="adminRefund" type="boolean">Whether the bet was refunded by an admin.</ResponseField>

    <Snippet file="types/game-summary.mdx" />
  </Expandable>
</ResponseField>

### Example

<CodeGroup>
  ```json JSON theme={null}
  {
    "data": {
      "matchedBets": [
        {
          "id": "67f45377c18c6697c172afa4",
          "txID": "67f45377c18c6697c172afa3",
          "type": "moneyline",
          "bet": 50,
          "odds": -185,
          "participantID": "5d48bd5198366d41ec7238da",
          "userReference": "my-ref-123",
          "createdAt": "2025-09-24T19:30:59.482Z",
          "matchedTime": "2025-09-24T19:30:59.482Z",
          "origin": "wager",
          "risk": "50.27",
          "win": "27.16",
          "fee": "0.27",
          "graded": false,
          "closed": false,
          "adminRefund": false,
          "game": {
            "id": "688c0516fbc14da0c202d426",
            "league": "NBA",
            "sport": "basketball",
            "start": "2025-09-25T00:10:00.000Z",
            "ended": false,
            "eventName": "TORONTO RAPTORS VS PHILADELPHIA 76ERS",
            "isFutures": false,
            "participants": [/* ... */]
          }
        }
      ]
    }
  }
  ```
</CodeGroup>


## OpenAPI

````yaml GET /user/getMatchedBets
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:
  /user/getMatchedBets:
    get:
      tags:
        - User
      summary: Get matched (ungraded) bets
      description: >-
        Return all of the caller's bets that have been matched but not yet
        graded.
      responses:
        '200':
          description: Matched bets list
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      matchedBets:
                        type: array
                        items:
                          $ref: '#/components/schemas/MatchedBet'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  schemas:
    MatchedBet:
      type: object
      description: A bet that has been matched but not yet graded.
      properties:
        id:
          type: string
        txID:
          type: string
        type:
          $ref: '#/components/schemas/MarketType'
        bet:
          type: number
        odds:
          type: integer
        spread:
          type: number
          nullable: true
        total:
          type: number
          nullable: true
        OU:
          type: string
          enum:
            - over
            - under
          description: Present for `total`.
        participantID:
          type: string
          description: Present for `moneyline` / `spread`.
        market:
          type: string
          description: Present for `moneyline1x2`.
        side:
          $ref: '#/components/schemas/MarketSide'
        userReference:
          type: string
        createdAt:
          type: string
          format: date-time
        matchedTime:
          type: string
          format: date-time
        graded:
          type: boolean
        closed:
          type: boolean
        origin:
          type: string
          description: '`offer` or `wager`.'
        adminRefund:
          type: boolean
        risk:
          type: string
        win:
          type: string
        fee:
          type: string
        game:
          $ref: '#/components/schemas/GameSummary'
    MarketType:
      type: string
      enum:
        - moneyline
        - spread
        - total
        - moneyline1x2
      description: >-
        Market type. `moneyline1x2` is **soccer-only** (three-way money line:
        home / away / draw).
    MarketSide:
      type: string
      description: |-
        Order side. Meaning depends on `type`:

        - `moneyline`, `spread` — the participant id you are backing.
        - `total` — `"over"` or `"under"`.
        - `moneyline1x2` — `"yes"` or `"no"` on the outcome named by `market`.
    GameSummary:
      type: object
      properties:
        id:
          type: string
        league:
          type: string
        sport:
          type: string
        start:
          type: string
          format: date-time
        ended:
          type: boolean
        eventName:
          type: string
          nullable: true
        isFutures:
          type: boolean
        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.

````