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

# Create a virtual account

> Create a bank-transfer virtual account.

Creates the account the user wires to, in one currency. Requires a registered
wallet that has accepted the terms of service and passed identity
verification.

Returns 204 with no body. Read
[List virtual accounts](/api/virtual-accounts/list) for the banking details to
show the user.


## OpenAPI

````yaml api/openapi.json POST /v1/virtual-accounts
openapi: 3.1.0
info:
  description: Fiat-to-USDC onramp API. The URL prefix (`/v1`) is the version contract.
  license:
    identifier: LicenseRef-Proprietary
    name: Proprietary
  title: Calm API
  version: v1
servers:
  - description: Production
    url: https://api.calmtreasury.xyz
  - description: Sandbox
    url: https://api.sandbox.calmtreasury.xyz
security: []
paths:
  /v1/virtual-accounts:
    post:
      summary: Create a virtual account
      description: >-
        Provisions a virtual account for a `(currency, destination chain, payout
        token)` triple. Repeating a triple returns the account that already
        exists. Changing `destination_token` on the same currency and chain
        provisions a separate account with its own bank details. Every chain is
        accepted. Requires an approved identity verification. Returns 204;
        refetch the list to see the new account.
      operationId: createVirtualAccount
      requestBody:
        content:
          application/json:
            schema:
              properties:
                currency:
                  enum:
                    - USD
                    - GBP
                    - EUR
                  type: string
                destination_chain:
                  enum:
                    - 1
                    - 8453
                    - 999
                    - 1337
                    - 4326
                    - 143
                    - 137
                    - 42161
                  type: number
                destination_token:
                  enum:
                    - USDC
                    - USDm
                    - AUSD
                    - USDC.e
                  type: string
                wallet:
                  pattern: ^0x[a-fA-F0-9]{40}$
                  type: string
              required:
                - wallet
                - currency
                - destination_chain
                - destination_token
              type: object
        required: true
      responses:
        '204':
          description: Virtual account provisioned.
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            Bad Request — `error.code` includes: deposit_address_unavailable,
            publishable_key_missing, unsupported_chain, validation_error.
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: 'Unauthorized — `error.code` includes: invalid_publishable_key.'
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: 'Forbidden — `error.code` includes: origin_not_allowed.'
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: 'Conflict — `error.code` includes: kyc_required.'
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: 'Too Many Requests — `error.code` includes: rate_limited.'
        '502':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            Bad Gateway — an upstream dependency failed; the body carries the
            standard error envelope with a cause-specific `error.code`.
      security:
        - publishableKey: []
components:
  schemas:
    Error:
      properties:
        error:
          properties:
            code:
              type: string
            message:
              type: string
          required:
            - code
            - message
          type: object
      required:
        - error
      type: object
  securitySchemes:
    publishableKey:
      description: Publishable key identifying the calling app.
      in: header
      name: x-calm-publishable-key
      type: apiKey

````