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

# Get Wallet

> Get the authenticated user wallet snapshot — address, SOL/USDC wallet balance, vault balance, and aggregated locked_amount across active RFQs and vault positions.



## OpenAPI

````yaml GET /v1/wallet
openapi: 3.0.3
info:
  title: Totalis RFQ API
  version: 2.1.0
  description: >-
    Public REST surface for the Totalis parlay RFQ platform — a decentralized
    request-for-quote marketplace for parlay bets across Kalshi and Polymarket,
    with on-chain Solana vault settlement.


    **Wire format**: snake_case JSON. All successful responses are wrapped in `{
    "data": ... }`; list endpoints add `meta` with cursor-based pagination.
    Errors use a `{ "error": { code, message, details? } }` envelope.


    **Authentication**: programmatic clients send `X-API-Key`; the web dashboard
    uses Privy JWTs (`Authorization: Bearer ...`). Any authenticated user can
    both place parlays and quote as a market maker — there is no separate MM
    role. Admin endpoints are out of scope for this public reference.


    **Rate limiting**: 100 req/min anonymous, 300 req/min authenticated.
    Responses include `X-RateLimit-*` headers. Request body limit: 256KB.


    **Pagination**: list endpoints use opaque cursor pagination. Pass
    `meta.cursor` from the previous response as `?cursor=...` to fetch the next
    page; do not parse or construct cursors client-side.
servers:
  - url: https://api.totalis.trade
    description: Production
security:
  - ApiKey: []
tags:
  - name: Markets
    description: Cached Kalshi and Polymarket market data.
  - name: User
    description: User profile, wallet, and devnet helpers.
  - name: API Keys
    description: Manage programmatic access keys for the authenticated user.
paths:
  /v1/wallet:
    get:
      tags:
        - User
      summary: Get Wallet
      description: >-
        Get the authenticated user's embedded Solana wallet address,
        wallet/vault balances, and the aggregated `locked_amount` across active
        RFQs and vault positions.
      operationId: getWallet
      responses:
        '200':
          description: Wallet snapshot
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Wallet'
        '401':
          $ref: '#/components/responses/Unauthorized'
      security:
        - PrivyJWT: []
        - ApiKey: []
components:
  schemas:
    Wallet:
      type: object
      properties:
        address:
          type: string
          nullable: true
          description: Solana wallet address (base58). Null if no wallet is linked yet.
        sol_balance:
          type: number
        usdc_balance:
          type: number
        vault_balance:
          type: number
          description: >-
            Gross USDC balance currently held in the caller's Totalis vault.
            Resolved by the returned `address`; returns 0 when no vault row
            exists for that wallet. Includes both free vault cash and locked
            collateral. Add to `usdc_balance` for total on-chain USDC across
            wallet and vault; subtract `locked_amount` from that total for an
            available-cash view.
        locked_amount:
          type: number
          description: >-
            Every USDC the caller has committed across roles: in-flight RFQs,
            bettor-side vault position stakes, and maker-side
            `locked_collateral`. Because `vault_balance` is gross, vault locked
            collateral is intentionally represented in both `vault_balance` and
            `locked_amount`; compute available cash as `usdc_balance +
            vault_balance - locked_amount` and do not add
            `/v1/vault.locked_collateral` again.
        has_traded:
          type: boolean
          description: >-
            True once any of the caller's parlays has reached `executed` or
            `settled`. Informational account state; withdrawals are allowed
            regardless of this value.
    ErrorEnvelope:
      type: object
      required:
        - error
      properties:
        error:
          $ref: '#/components/schemas/ErrorBody'
    ErrorBody:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          enum:
            - VALIDATION_ERROR
            - UNAUTHORIZED
            - FORBIDDEN
            - NOT_FOUND
            - CONFLICT
            - RATE_LIMITED
            - PAYLOAD_TOO_LARGE
            - INTERNAL_ERROR
            - SERVICE_UNAVAILABLE
          description: Machine-readable error code.
        message:
          type: string
          description: Human-readable error message.
        details:
          type: object
          description: Additional error context.
        retry_after:
          type: integer
          nullable: true
          description: Seconds until retry; set on 429 responses.
  responses:
    Unauthorized:
      description: Missing or invalid authentication
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
          example:
            error:
              code: UNAUTHORIZED
              message: Missing or invalid authentication
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Programmatic API key. Sent as `X-API-Key: <key>`. Generate one from the
        Totalis dashboard. The same header is accepted on the WebSocket auth
        message.
    PrivyJWT:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Privy JWT issued to the web dashboard. Sent as `Authorization: Bearer
        <jwt>`. The Privy session signer underpins all wallet-signed actions.

````