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

# List deposits

> Recent deposits into the key’s trading account on one venue, newest first, at most 50, each with its status. Only deposits sent to the addresses from GET /deposits/addresses through a provider are listed: Relay for Hyperliquid and the Polymarket bridge for Polymarket. Sending pUSD straight to the Polymarket wallet credits it at once and is not listed. A test key gets an empty list.



## OpenAPI

````yaml api-reference/openapi.json GET /deposits
openapi: 3.0.0
info:
  title: Lean API
  version: 0.1.0
  description: >-
    Programmatic access to Lean: canonical sports markets, quotes, orders,
    positions and balances.
servers:
  - url: '{baseUrl}/v1'
    description: Lean API
    variables:
      baseUrl:
        default: https://api.lean.xyz
        description: >-
          The Lean API base URL, without /v1. Same value as LEAN_API_URL in the
          guides.
security:
  - apiKey: []
paths:
  /deposits:
    get:
      tags:
        - Deposits
      summary: List deposits
      description: >-
        Recent deposits into the key’s trading account on one venue, newest
        first, at most 50, each with its status. Only deposits sent to the
        addresses from GET /deposits/addresses through a provider are listed:
        Relay for Hyperliquid and the Polymarket bridge for Polymarket. Sending
        pUSD straight to the Polymarket wallet credits it at once and is not
        listed. A test key gets an empty list.
      operationId: listDeposits
      parameters:
        - schema:
            type: string
            enum:
              - polymarket
              - hyperliquid
          required: true
          name: venue
          in: query
      responses:
        '200':
          description: Recent deposits with their status
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    properties:
                      success:
                        type: boolean
                        enum:
                          - true
                      data:
                        type: object
                        properties:
                          deposits:
                            type: array
                            items:
                              oneOf:
                                - type: object
                                  properties:
                                    venue:
                                      type: string
                                      enum:
                                        - hyperliquid
                                    provider:
                                      type: string
                                      enum:
                                        - relay
                                    id:
                                      type: string
                                      minLength: 1
                                    address_type:
                                      type: string
                                      enum:
                                        - evm
                                        - svm
                                    status:
                                      type: string
                                      enum:
                                        - detected
                                        - processing
                                        - completed
                                        - failed
                                        - refunded
                                      description: >-
                                        detected once funds reach the deposit
                                        address, processing while the provider
                                        moves them, then completed when the
                                        venue is credited, failed, or refunded
                                        to the sender.
                                    credited_amount:
                                      type: object
                                      nullable: true
                                      properties:
                                        amount:
                                          type: string
                                          pattern: ^\d+(?:\.\d+)?$
                                        asset:
                                          type: string
                                          minLength: 1
                                      required:
                                        - amount
                                        - asset
                                      description: >-
                                        What the venue was credited. Null until
                                        the deposit completes.
                                    source_amount:
                                      type: object
                                      nullable: true
                                      properties:
                                        amount:
                                          type: string
                                          pattern: ^\d+(?:\.\d+)?$
                                        symbol:
                                          type: string
                                          minLength: 1
                                      required:
                                        - amount
                                        - symbol
                                      description: >-
                                        What was sent, when the provider reports
                                        it but not the amount credited. Null
                                        otherwise.
                                    transactions:
                                      type: array
                                      items:
                                        type: object
                                        properties:
                                          kind:
                                            type: string
                                            enum:
                                              - deposit
                                              - completion
                                            description: >-
                                              deposit is the transfer into the deposit
                                              address; completion is the transfer that
                                              credited the venue.
                                          hash:
                                            type: string
                                            minLength: 1
                                          chain_id:
                                            type: string
                                            minLength: 1
                                          timestamp:
                                            type: string
                                            nullable: true
                                            format: date-time
                                        required:
                                          - kind
                                          - hash
                                          - chain_id
                                          - timestamp
                                    started_at:
                                      type: string
                                      nullable: true
                                      format: date-time
                                    completed_at:
                                      type: string
                                      nullable: true
                                      format: date-time
                                  required:
                                    - venue
                                    - provider
                                    - id
                                    - address_type
                                    - status
                                    - credited_amount
                                    - source_amount
                                    - transactions
                                    - started_at
                                    - completed_at
                                - type: object
                                  properties:
                                    venue:
                                      type: string
                                      enum:
                                        - polymarket
                                    provider:
                                      type: string
                                      enum:
                                        - polymarket_wallet
                                        - polymarket_bridge
                                    id:
                                      type: string
                                      minLength: 1
                                    address_type:
                                      type: string
                                      enum:
                                        - evm
                                        - svm
                                    status:
                                      type: string
                                      enum:
                                        - detected
                                        - processing
                                        - completed
                                        - failed
                                        - refunded
                                      description: >-
                                        detected once funds reach the deposit
                                        address, processing while the provider
                                        moves them, then completed when the
                                        venue is credited, failed, or refunded
                                        to the sender.
                                    credited_amount:
                                      type: object
                                      nullable: true
                                      properties:
                                        amount:
                                          type: string
                                          pattern: ^\d+(?:\.\d+)?$
                                        asset:
                                          type: string
                                          minLength: 1
                                      required:
                                        - amount
                                        - asset
                                      description: >-
                                        What the venue was credited. Null until
                                        the deposit completes.
                                    source_amount:
                                      type: object
                                      nullable: true
                                      properties:
                                        amount:
                                          type: string
                                          pattern: ^\d+(?:\.\d+)?$
                                        symbol:
                                          type: string
                                          minLength: 1
                                      required:
                                        - amount
                                        - symbol
                                      description: >-
                                        What was sent, when the provider reports
                                        it but not the amount credited. Null
                                        otherwise.
                                    transactions:
                                      type: array
                                      items:
                                        type: object
                                        properties:
                                          kind:
                                            type: string
                                            enum:
                                              - deposit
                                              - completion
                                            description: >-
                                              deposit is the transfer into the deposit
                                              address; completion is the transfer that
                                              credited the venue.
                                          hash:
                                            type: string
                                            minLength: 1
                                          chain_id:
                                            type: string
                                            minLength: 1
                                          timestamp:
                                            type: string
                                            nullable: true
                                            format: date-time
                                        required:
                                          - kind
                                          - hash
                                          - chain_id
                                          - timestamp
                                    started_at:
                                      type: string
                                      nullable: true
                                      format: date-time
                                    completed_at:
                                      type: string
                                      nullable: true
                                      format: date-time
                                  required:
                                    - venue
                                    - provider
                                    - id
                                    - address_type
                                    - status
                                    - credited_amount
                                    - source_amount
                                    - transactions
                                    - started_at
                                    - completed_at
                            maxItems: 50
                          livemode:
                            type: boolean
                        required:
                          - deposits
                          - livemode
                      meta:
                        type: object
                        properties:
                          timestampMs:
                            type: integer
                            minimum: 0
                          requestId:
                            type: string
                            minLength: 1
                          traceId:
                            type: string
                            minLength: 1
                          cachedAtMs:
                            type: integer
                            minimum: 0
                          source:
                            type: string
                            enum:
                              - cache
                              - database
                              - clickhouse
                              - upstream
                              - fallback
                              - internal
                        required:
                          - timestampMs
                          - requestId
                    required:
                      - success
                      - data
                      - meta
                  - $ref: '#/components/schemas/ApiError'
              example:
                success: true
                data:
                  deposits:
                    - venue: hyperliquid
                      provider: relay
                      address_type: evm
                      id: >-
                        0x4c1f0e6a9b0d2e7f3a8c5d1b6e9f2a7c4d0b3e8f1a6c9d2e5b8f1a4c7d0e3b6f
                      status: completed
                      credited_amount:
                        amount: '250'
                        asset: USDC
                      source_amount: null
                      transactions:
                        - kind: deposit
                          hash: >-
                            0x9e2d4f6a8c0b1e3d5f7a9c2b4e6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a5c7e9b2d
                          chain_id: '42161'
                          timestamp: '2026-11-17T02:14:05.000Z'
                      started_at: '2026-11-17T02:14:05.000Z'
                      completed_at: '2026-11-17T02:14:41.000Z'
                  livemode: true
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '400':
          description: Invalid venue, or the trading account is not set up on it
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: VALIDATION_ERROR
                  message: Invalid venue, or the trading account is not set up on it
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '401':
          description: Missing, invalid, expired or revoked API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: UNAUTHORIZED
                  message: Invalid, expired or revoked API key
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '403':
          description: The key lacks the scope this route needs
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: FORBIDDEN
                  message: This API key lacks the scope this route needs
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '429':
          description: API error
          headers:
            Retry-After:
              description: Seconds remaining in the upstream read cooldown, when available
              schema:
                type: integer
                minimum: 0
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: RATE_LIMITED
                  message: Too many requests for this API key
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '500':
          description: API error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: INTERNAL_ERROR
                  message: An internal error occurred.
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
        '503':
          description: The deposit provider is unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                success: false
                error:
                  code: UPSTREAM_ERROR
                  message: The deposit provider is unavailable
                meta:
                  timestampMs: 1792771200000
                  requestId: 7d2c9f4e-1b3a-4e8d-9c6f-2a5b8e0d4f17
components:
  schemas:
    ApiError:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - false
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - VALIDATION_ERROR
                - NOT_FOUND
                - UNAUTHORIZED
                - FORBIDDEN
                - CONFLICT
                - UPSTREAM_ERROR
                - RATE_LIMITED
                - INTERNAL_ERROR
                - FEATURE_DISABLED
                - CONDITIONAL_SELL_REJECTED
                - CONDITIONAL_SELL_ACTIVE
            message:
              type: string
              minLength: 1
            details:
              nullable: true
          required:
            - code
            - message
        meta:
          type: object
          properties:
            timestampMs:
              type: integer
              minimum: 0
            requestId:
              type: string
              minLength: 1
            traceId:
              type: string
              minLength: 1
            cachedAtMs:
              type: integer
              minimum: 0
            source:
              type: string
              enum:
                - cache
                - database
                - clickhouse
                - upstream
                - fallback
                - internal
          required:
            - timestampMs
            - requestId
      required:
        - success
        - error
        - meta
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: >-
        A Lean API key, sent as `Authorization: Bearer <key>`. A test key
        (`lean_sk_test_...`) simulates orders and fills with no money; a live
        key (`lean_sk_live_...`) trades for real within the key's limits. Every
        successful response says which mode answered in `data.livemode`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.