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

# Claim a settled position without paying gas

> Enqueues a `redeem_positions` meta-tx for the submitter to broadcast on the user's behalf — the user pays no gas. Identify the position by `(marketId, outcomeIndex)` (the compound key on every `Position` from `GET /api/me/positions`); the server re-reads the authoritative position from exchange-service, verifies it is redeemable, builds the on-chain payload itself (binary conditionId+indexSets or neg-risk marketId+questionIndex+amount — client-supplied payloads are deliberately not accepted), and queues the job. Returns `{ jobId, status }`; poll `GET /api/me/positions/redeem/{jobId}` until the job confirms. The credited payout then appears on the vault balance via the standard PositionRedeemed pipeline. API-key (partner) callers MUST include the owner-signed `auth` bundle (EIP-712 RedeemAuthorization); Privy-JWT (retail) callers omit it. Failures: 400 `not_redeemable` / `neg_risk_not_ready` / `no_quantity` / `no_condition_id`; 403 `no_vault`; 404 `position_not_found`. Rate limit: 10/60s per wallet. Requires `vault:write` scope and deposit tier ≥ 1.



## OpenAPI

````yaml /api-reference/openapi.json post /api/me/positions/redeem
openapi: 3.1.0
info:
  title: PredictStreet core-api
  description: >-
    Client-facing HTTP gateway for the PredictStreet prediction-market platform.
    **Partner kinds.** Every authenticated endpoint resolves a request's
    *effective wallet* from the partner row. `single_wallet` partners bind to
    one `associatedWallet` set at creation. `multi_wallet` partners declare the
    actor on every request via an `X-User-Wallet: 0x<40-hex>` header. See the
    [Partner kinds](/auth/api-keys#partner-kinds) doc for the full contract.
  version: '2026-04-25'
  contact:
    name: PredictStreet partners
    email: partners@predictstreet.com
servers:
  - url: https://core-api.adipredictstreet.com
    description: Production — replace with the API host issued at partner onboarding.
security: []
tags:
  - name: Events
    description: >-
      Polymarket-style event grouping with football metadata (group, stage,
      teams, tags).
  - name: Tags
    description: Curated tag taxonomy used to filter events.
  - name: Markets
    description: 'Public market data: list, detail, orderbook, trades, OHLC.'
  - name: Orders
    description: >-
      Signed-order place / cancel / read. Requires `X-Api-Key` with
      `orders:read` / `orders:write` scope; every write additionally requires an
      EIP-712 signature over the order.
  - name: Portfolio
    description: >-
      Balances, positions, trades, fees, vault info for the key's
      `associatedWallet`. Requires `X-Api-Key` with `portfolio:read` scope.
  - name: Matches
    description: >-
      admin.matches aggregate — groups several events into one fixture/card (1X2
      + first-scorer + over-under under one matchup).
  - name: Vault
    description: >-
      Backend co-signatures for ERC-1155 split / merge, and recovery for
      off-chain locks when the corresponding chain tx never confirmed. Requires
      `X-Api-Key` with `vault:write` scope plus an EIP-712 signature over the
      operation.
  - name: Leaderboard
    description: Public ranked leaderboard across PnL / volume buckets.
  - name: Search
    description: Global search across users, events, and matches.
paths:
  /api/me/positions/redeem:
    post:
      tags:
        - Portfolio
      summary: Claim a settled position without paying gas
      description: >-
        Enqueues a `redeem_positions` meta-tx for the submitter to broadcast on
        the user's behalf — the user pays no gas. Identify the position by
        `(marketId, outcomeIndex)` (the compound key on every `Position` from
        `GET /api/me/positions`); the server re-reads the authoritative position
        from exchange-service, verifies it is redeemable, builds the on-chain
        payload itself (binary conditionId+indexSets or neg-risk
        marketId+questionIndex+amount — client-supplied payloads are
        deliberately not accepted), and queues the job. Returns `{ jobId, status
        }`; poll `GET /api/me/positions/redeem/{jobId}` until the job confirms.
        The credited payout then appears on the vault balance via the standard
        PositionRedeemed pipeline. API-key (partner) callers MUST include the
        owner-signed `auth` bundle (EIP-712 RedeemAuthorization); Privy-JWT
        (retail) callers omit it. Failures: 400 `not_redeemable` /
        `neg_risk_not_ready` / `no_quantity` / `no_condition_id`; 403
        `no_vault`; 404 `position_not_found`. Rate limit: 10/60s per wallet.
        Requires `vault:write` scope and deposit tier ≥ 1.
      operationId: RedeemController_create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RedeemRequestDto'
      responses:
        '200':
          description: >-
            Job accepted (idempotent on payload hash — an identical in-flight
            redeem returns the existing job).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RedeemRespDto'
      security:
        - access: []
components:
  schemas:
    RedeemRequestDto:
      type: object
      properties:
        marketId:
          type: string
          example: PM-WC26-R16-USA-WC26-1910V2
          description: >-
            Market identifier of the position to redeem — the `marketId` field
            from the `Position` payload (`GET /api/me/positions`).
        outcomeIndex:
          type: integer
          minimum: 0
          maximum: 255
          example: 0
          description: >-
            Outcome index of the held position (0 = YES, 1 = NO). For binary
            markets this scopes the CTF indexSets bitmask to the single side the
            user holds; for neg-risk it only disambiguates which Position row to
            read (the adapter burns both sides in one call regardless).
        auth:
          $ref: '#/components/schemas/RedeemAuthDto'
      required:
        - marketId
        - outcomeIndex
    RedeemRespDto:
      type: object
      properties:
        jobId:
          type: string
          example: '4210'
          description: >-
            Submitter job id (decimal string). Polling key for the status
            endpoint.
        status:
          type: string
          example: pending
          description: >-
            Live submitter-job status: pending | building | submitted |
            confirmed | failed_permanent | expired.
      required:
        - jobId
        - status
    RedeemAuthDto:
      type: object
      properties:
        deadline:
          type: integer
          example: 1999999999
          description: >-
            Unix-seconds deadline the owner signed into the RedeemAuthorization.
            The server rejects (`redeem_expired`) once it has elapsed.
        v:
          type: integer
          example: 27
          description: ECDSA recovery id (27/28 or 0/1).
        r:
          type: string
          minLength: 66
          maxLength: 66
          description: 32-byte r component, 0x-prefixed hex.
        s:
          type: string
          minLength: 66
          maxLength: 66
          description: 32-byte s component, 0x-prefixed hex.
      required:
        - deadline
        - v
        - r
        - s
      description: >-
        Owner-signed EIP-712 RedeemAuthorization bundle. REQUIRED only for
        API-key (partner) callers — it binds the redeem to the wallet owner so a
        spoofable X-User-Wallet header cannot force a third-party redeem.
        Privy-JWT (retail) callers omit it. Signed struct:
        RedeemAuthorization{owner, marketId, outcomeIndex, deadline} under
        domain {name:'PredictStreetRedeem', version:'1', chainId}.

````