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

# Create an onramp

> Create an onramp transaction converting fiat to stablecoins. The source funds
either from a user's own account (`source.userId` + `source.transferType`) or
from a saved external account (`source.externalAccountId`). The destination
delivers crypto to either a HIFI-hosted wallet (`destination.walletId`) or a
saved external wallet (`destination.externalWalletId`). Exactly one amount
(`source.amount` or `destination.amount`) must be provided.




## OpenAPI

````yaml https://production.hifi.com/api/v3/openapi.json post /v3/onramps
openapi: 3.0.0
info:
  title: Hifi API
  version: 3.0.0
  description: API documentation for HIFI
servers:
  - url: https://production.hifi.com
    description: Production server
  - url: https://sandbox.hifi.com
    description: Sandbox server
security:
  - bearerAuth: []
tags:
  - name: Common
    description: Common endpoints
  - name: User
    description: User endpoints
  - name: Counter Party
    description: Counter party endpoints
  - name: Crypto Transfer
    description: Crypto transfer and batch transfer endpoints
  - name: Wallet
    description: Wallet and wallet offer endpoints
  - name: External Account
    description: External bank account endpoints (under a counter party)
  - name: External Wallet
    description: External wallet endpoints (under a counter party)
  - name: External Card
    description: External card endpoints (under a counter party)
  - name: Token Swap
    description: Token swap endpoints
  - name: Bridge
    description: Bridge endpoints
  - name: Virtual Account
    description: Virtual account endpoints
  - name: Compliance
    description: Compliance and compliance link endpoints
  - name: Webhook Endpoint
    description: Webhook endpoint endpoints
  - name: File
    description: File upload endpoints
  - name: Onramp
    description: Onramp (fiat to crypto) endpoints
  - name: Offramp
    description: Offramp (crypto to fiat) endpoints
  - name: Orchestration Address
    description: Orchestration (liquidation) address endpoints
  - name: KYC Link
    description: Hosted and custom KYC/KYB link endpoints
  - name: Transfer Approval
    description: Transfer approval endpoints
  - name: Corridor
    description: Supported fiat/crypto transfer corridor endpoints
  - name: Migration
    description: v2-to-v3 ID mapping endpoints
paths:
  /v3/onramps:
    post:
      tags:
        - Onramp
      summary: Create an onramp
      description: >
        Create an onramp transaction converting fiat to stablecoins. The source
        funds

        either from a user's own account (`source.userId` +
        `source.transferType`) or

        from a saved external account (`source.externalAccountId`). The
        destination

        delivers crypto to either a HIFI-hosted wallet (`destination.walletId`)
        or a

        saved external wallet (`destination.externalWalletId`). Exactly one
        amount

        (`source.amount` or `destination.amount`) must be provided.
      operationId: v3CreateOnramp
      requestBody:
        $ref: '#/components/requestBodies/CreateOnrampBody'
      responses:
        '200':
          $ref: '#/components/responses/CreateOnrampResponse'
        '400':
          $ref: '#/components/responses/BadRequestResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedResponse'
        '409':
          $ref: '#/components/responses/ConflictResponse'
        '500':
          $ref: '#/components/responses/InternalServerErrorResponse'
components:
  requestBodies:
    CreateOnrampBody:
      required: true
      description: >
        Onramp details. Provide exactly one of `source.userId` /
        `source.externalAccountId`,

        exactly one of `source.transferType` / `source.externalAccountId`,
        exactly one of

        `destination.walletId` / `destination.externalWalletId`, and exactly one
        of

        `source.amount` / `destination.amount`.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/OnrampCreateBody'
          examples:
            FundFromUserToWallet:
              summary: Fund from a user via ACH to a HIFI wallet
              value:
                requestId: b3d1f2a4-5c6e-7890-abcd-ef1234567890
                source:
                  amount: 100
                  currency: USD
                  transferType: ACH
                  userId: usr_3Kf9dQ2mNpXwZ7bV1aLcs
                destination:
                  currency: USDC
                  walletId: wlt_1aLcs3Kf9dQ2mNpXwZ7bV
                sameDayAch: false
                description: Monthly top-up
            FundFromExternalAccountToExternalWallet:
              summary: Fund from a saved external account to an external wallet
              value:
                requestId: c4e2a3b5-6d7f-8901-bcde-f23456789012
                source:
                  amount: 250
                  currency: USD
                  externalAccountId: extacct_9aB0xY4mNpXwZ7bV1aLdt
                destination:
                  currency: USDT
                  externalWalletId: extw_4mNpXwZ7bV1aLcs3Kf9dQ
  responses:
    CreateOnrampResponse:
      description: Onramp created successfully.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/OnrampObject'
          example:
            id: onramp_7bV1aLcs3Kf9dQ2mNpXwZ
            requestId: b3d1f2a4-5c6e-7890-abcd-ef1234567890
            status: AWAITING_FUNDS
            failedReason: null
            error: null
            errorDetails: null
            source:
              amount: 100
              currency: USD
              userId: usr_3Kf9dQ2mNpXwZ7bV1aLcs
              externalAccountId: null
              virtualAccountId: null
              depositInstructions:
                bankName: Cross River Bank
                bankAddress: 2115 Linwood Ave, Fort Lee, NJ 07024
                beneficiary:
                  name: HIFI Bridge Inc
                  address: 123 Main Street, New York, NY, 10001, USA
                ach:
                  routingNumber: '021000021'
                  accountNumber: '123456789'
                wire:
                  routingNumber: '021000021'
                  accountNumber: '123456789'
                rtp:
                  routingNumber: '021000021'
                  accountNumber: '123456789'
                reference: HIFI-9A2B
                depositBy: '2026-07-02T10:30:00.000Z'
                instruction: >-
                  Please deposit USD to the bank account provided. For USDT
                  onramp, a minimum of $10 is required, or the funds will be
                  returned.
              depositTracking: null
            destination:
              chain: POLYGON
              amount: 100
              currency: USDC
              userId: usr_3Kf9dQ2mNpXwZ7bV1aLcs
              walletId: wlt_1aLcs3Kf9dQ2mNpXwZ7bV
              externalWalletId: null
              walletAddress: '0x1234567890abcdef1234567890abcdef12345678'
            receipt:
              transactionHash: null
            settlement: null
            quote:
              sendGross:
                amount: '100.00'
                currency: USD
              sendNet:
                amount: '100.00'
                currency: USD
              railFee:
                amount: '0.00'
                currency: USDC
              receiveGross:
                amount: '100.00'
                currency: USDC
              receiveNet:
                amount: '100.00'
                currency: USDC
              rate: '1.00'
              conversionFee:
                amount: '0'
                currency: USDC
                description: No conversion fee applicable
                timing: N/A
              expiresAt: N/A
            microDeposits:
              count: 0
              data: []
            sameDayAch: false
            description: Monthly top-up
            createdAt: '2026-07-01T10:30:00.000Z'
            updatedAt: '2026-07-01T10:30:00.000Z'
    BadRequestResponse:
      description: Bad Request — the request was malformed or failed validation.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            type: VALIDATION_ERROR
            message: One or more fields are invalid or missing.
            fields:
              - code: invalid_value
                message: Must be a valid email address
                field: email
    UnauthorizedResponse:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Unauthorized'
    ConflictResponse:
      description: >-
        Conflict — the request collides with the current state of the resource
        (e.g. idempotency-key reuse with a different payload).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            type: RESOURCE_CONFLICT
            message: Resource already exists or conflicts with current state
    InternalServerErrorResponse:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/InternalServerError'
  schemas:
    OnrampCreateBody:
      type: object
      description: >
        Create an onramp. Provide exactly one of `source.userId` /
        `source.externalAccountId`,

        exactly one of `source.transferType` / `source.externalAccountId`,
        exactly one of

        `destination.walletId` / `destination.externalWalletId`, and exactly one
        of

        `source.amount` / `destination.amount`.
      required:
        - requestId
        - source
        - destination
      properties:
        requestId:
          type: string
          format: uuid
          description: >-
            Client-supplied idempotency key. A second create with the same value
            returns a conflict.
          example: b3d1f2a4-5c6e-7890-abcd-ef1234567890
        source:
          $ref: '#/components/schemas/OnrampCreateSource'
        destination:
          $ref: '#/components/schemas/OnrampCreateDestination'
        sameDayAch:
          type: boolean
          description: Whether to use same-day ACH settlement.
          example: false
        purposeOfPayment:
          type: string
          description: Purpose of the payment.
          example: Investment
        description:
          type: string
          description: Free-form description for the onramp.
          example: Monthly top-up
    OnrampObject:
      type: object
      description: An onramp transaction.
      properties:
        id:
          type: string
          description: Public ID of the onramp (prefixed with `onramp_`).
          example: onramp_7bV1aLcs3Kf9dQ2mNpXwZ
        requestId:
          type: string
          format: uuid
          description: Client-supplied idempotency key from the create request.
          example: b3d1f2a4-5c6e-7890-abcd-ef1234567890
        status:
          $ref: '#/components/schemas/OnrampStatus'
        failedReason:
          type: string
          nullable: true
          description: Machine-readable reason when the onramp failed.
          example: null
        error:
          type: string
          nullable: true
          description: User-facing error summary when the onramp failed.
          example: null
        errorDetails:
          type: string
          nullable: true
          description: User-facing error detail when the onramp failed.
          example: null
        source:
          type: object
          properties:
            amount:
              type: number
              nullable: true
              example: 100
            currency:
              type: string
              enum:
                - USD
              example: USD
            userId:
              type: string
              nullable: true
              description: Public ID of the funding user (prefixed with `usr_`).
              example: usr_3Kf9dQ2mNpXwZ7bV1aLcs
            externalAccountId:
              type: string
              nullable: true
              description: >-
                Public ID of the funding external account (prefixed with
                `extacct_`).
              example: null
            virtualAccountId:
              type: string
              nullable: true
              description: Public ID of the funding virtual account (prefixed with `va_`).
              example: null
            depositInstructions:
              $ref: '#/components/schemas/OnrampDepositInstructions'
            depositTracking:
              $ref: '#/components/schemas/OnrampDepositTracking'
        destination:
          type: object
          properties:
            chain:
              type: string
              enum:
                - ETHEREUM
                - POLYGON
                - SOLANA
                - BASE
                - OPTIMISM
                - ARBITRUM
                - FLOW_EVM
                - CANTON
                - TRON
                - BSC
                - XRPL
              example: POLYGON
            amount:
              type: number
              nullable: true
              example: 100
            currency:
              type: string
              enum:
                - USDC
                - USDT
                - PYUSD0
              example: USDC
            userId:
              type: string
              nullable: true
              description: Public ID of the receiving user (prefixed with `usr_`).
              example: usr_3Kf9dQ2mNpXwZ7bV1aLcs
            walletId:
              type: string
              nullable: true
              description: Public ID of the receiving HIFI wallet (prefixed with `wlt_`).
              example: wlt_1aLcs3Kf9dQ2mNpXwZ7bV
            externalWalletId:
              type: string
              nullable: true
              description: >-
                Public ID of the receiving external wallet (prefixed with
                `extw_`).
              example: null
            walletAddress:
              type: string
              nullable: true
              example: '0x1234567890abcdef1234567890abcdef12345678'
        receipt:
          type: object
          properties:
            transactionHash:
              type: string
              nullable: true
              description: On-chain transaction hash of the delivered crypto.
              example: null
        settlement:
          nullable: true
          description: Settlement breakdown once funds settle.
        quote:
          $ref: '#/components/schemas/OnrampQuote'
        microDeposits:
          $ref: '#/components/schemas/OnrampMicroDeposits'
        sameDayAch:
          type: boolean
          example: false
        description:
          type: string
          nullable: true
          example: Monthly top-up
        createdAt:
          type: string
          format: date-time
          example: '2026-07-01T10:30:00.000Z'
        updatedAt:
          type: string
          format: date-time
          example: '2026-07-01T10:30:00.000Z'
    ApiError:
      type: object
      description: >-
        Standard v3 error shape, returned by validation failures and
        business-logic errors alike.
      properties:
        type:
          type: string
          description: >-
            Machine-readable error type, e.g. VALIDATION_ERROR,
            ACTION_NOT_ALLOWED, RESOURCE_CONFLICT.
          example: VALIDATION_ERROR
        message:
          type: string
          description: Human-readable error message.
          example: One or more fields are invalid or missing.
        fields:
          type: array
          description: >-
            Present on field-level validation errors. One entry per problem
            field.
          items:
            type: object
            properties:
              code:
                type: string
                description: Error code related to the field issue.
              message:
                type: string
                description: Error message for the specific issue.
              field:
                type: string
                description: The name of the field that has an issue.
    Unauthorized:
      type: object
      properties:
        type:
          type: string
          description: Unauthorized enum
          example: UNAUTHORIZED
        message:
          type: string
          description: Unauthorized message
          example: Authentication required
    InternalServerError:
      type: object
      properties:
        type:
          type: string
          example: INTERNAL_SERVER_ERROR
          description: Internal server error enum
        message:
          type: string
          example: An internal server error occurred
          description: Internal server error message
    OnrampCreateSource:
      type: object
      description: Source of the fiat funds.
      required:
        - currency
      properties:
        amount:
          type: number
          description: >
            Source amount in the source currency. Provide either `source.amount`
            or

            `destination.amount`, never both. When `destination.currency` is
            `USDT`,

            the source amount must be at least 10.
          example: 100
        currency:
          type: string
          description: Source fiat currency.
          enum:
            - USD
          example: USD
        transferType:
          type: string
          description: >
            Fiat rail used to fund the onramp. Provide when funding from a
            user's own

            account; mutually exclusive with `externalAccountId`.
          enum:
            - ACH
            - WIRE
            - RTP
          example: ACH
        userId:
          type: string
          description: >
            Public ID of the user funding the onramp (prefixed with `usr_`).
            Mutually

            exclusive with `externalAccountId`.
          example: usr_3Kf9dQ2mNpXwZ7bV1aLcs
        externalAccountId:
          type: string
          description: |
            Public ID of a saved external account to fund from (prefixed with
            `extacct_`). Mutually exclusive with `userId` and `transferType`.
          example: extacct_9aB0xY4mNpXwZ7bV1aLdt
    OnrampCreateDestination:
      type: object
      description: Destination for the delivered crypto.
      required:
        - currency
      properties:
        amount:
          type: number
          description: |
            Destination amount in the destination currency. Provide either
            `source.amount` or `destination.amount`, never both.
          example: 100
        currency:
          type: string
          description: Destination crypto currency.
          enum:
            - USDC
            - USDT
            - PYUSD0
          example: USDC
        walletId:
          type: string
          description: >
            Public ID of a HIFI-hosted wallet to receive the crypto (prefixed
            with

            `wlt_`). Mutually exclusive with `externalWalletId`.
          example: wlt_1aLcs3Kf9dQ2mNpXwZ7bV
        externalWalletId:
          type: string
          description: >
            Public ID of a saved external wallet to receive the crypto (prefixed
            with

            `extw_`). Mutually exclusive with `walletId`.
          example: extw_4mNpXwZ7bV1aLcs3Kf9dQ
    OnrampStatus:
      type: string
      description: Lifecycle status of the onramp transaction.
      enum:
        - NOT_INITIATED
        - CREATED
        - OPEN_QUOTE
        - IN_REVIEW
        - FIAT_INITIATED
        - AWAITING_FUNDS
        - FIAT_PENDING
        - FIAT_PROCESSED
        - CRYPTO_INITIATED
        - CRYPTO_PENDING
        - COMPLETED
        - FIAT_FAILED
        - FIAT_RETURNED
        - CRYPTO_FAILED
        - QUOTE_FAILED
        - EXPIRED
        - UNKNOWN
        - CANCELLED
      example: AWAITING_FUNDS
    OnrampDepositInstructions:
      type: object
      nullable: true
      description: |
        Bank details for funding the onramp. Present only while the onramp is
        awaiting funds and no virtual or source account is attached.
      properties:
        bankName:
          type: string
          example: Cross River Bank
        bankAddress:
          type: string
          example: 2115 Linwood Ave, Fort Lee, NJ 07024
        beneficiary:
          type: object
          properties:
            name:
              type: string
              example: HIFI Bridge Inc
            address:
              type: string
              example: 123 Main Street, New York, NY, 10001, USA
        ach:
          type: object
          properties:
            routingNumber:
              type: string
              example: '021000021'
            accountNumber:
              type: string
              example: '123456789'
        wire:
          type: object
          properties:
            routingNumber:
              type: string
              example: '021000021'
            accountNumber:
              type: string
              example: '123456789'
        rtp:
          type: object
          properties:
            routingNumber:
              type: string
              example: '021000021'
            accountNumber:
              type: string
              example: '123456789'
        reference:
          type: string
          nullable: true
          example: HIFI-9A2B
        depositBy:
          type: string
          format: date-time
          nullable: true
          example: '2026-07-02T10:30:00.000Z'
        instruction:
          type: string
          example: >-
            Please deposit USD to the bank account provided. For USDT onramp, a
            minimum of $10 is required, or the funds will be returned.
    OnrampDepositTracking:
      type: object
      nullable: true
      description: Details of the inbound fiat payment once received.
      properties:
        bankName:
          type: string
          example: Chase Bank
        senderName:
          type: string
          example: John Doe
        routingNumber:
          type: string
          example: '021000021'
        accountNumber:
          type: string
          example: '123456789'
        accountType:
          type: string
          example: CHECKING
        fedBatchId:
          type: string
          example: '20260701001'
        imad:
          type: string
          example: 20260701MMQFMPH5000001
        omad:
          type: string
          example: 20260701QMGFT025000123
        traceNumber:
          type: string
          example: '021000020123456'
        bankAddress:
          type: string
          example: 270 Park Avenue, New York, NY, USA
        description:
          type: string
          example: Onramp deposit
        references:
          type: object
          nullable: true
          properties:
            senderReference:
              type: string
              example: REF-12345
            beneficiaryReference:
              type: string
              example: HIFI-9A2B
            remittance:
              type: array
              items:
                type: string
        paymentRail:
          type: string
          example: ach
    OnrampQuote:
      type: object
      description: Conversion quote for the onramp.
      properties:
        sendGross:
          type: object
          properties:
            amount:
              type: string
              example: '100.00'
            currency:
              type: string
              example: USD
        sendNet:
          type: object
          properties:
            amount:
              type: string
              example: '100.00'
            currency:
              type: string
              example: USD
        railFee:
          type: object
          properties:
            amount:
              type: string
              example: '0.00'
            currency:
              type: string
              example: USDC
        receiveGross:
          type: object
          properties:
            amount:
              type: string
              example: '100.00'
            currency:
              type: string
              example: USDC
        receiveNet:
          type: object
          properties:
            amount:
              type: string
              example: '100.00'
            currency:
              type: string
              example: USDC
        rate:
          type: string
          example: '1.00'
        conversionFee:
          type: object
          properties:
            amount:
              type: string
              example: '0'
            currency:
              type: string
              example: USDC
            description:
              type: string
              example: No conversion fee applicable
            timing:
              type: string
              example: N/A
        expiresAt:
          type: string
          description: ISO timestamp when the quote expires, or `N/A` for static quotes.
          example: N/A
    OnrampMicroDeposits:
      type: object
      description: Micro-deposits received against the onramp while awaiting funds.
      properties:
        count:
          type: integer
          example: 0
        data:
          type: array
          items:
            type: object
            properties:
              createdAt:
                type: string
                format: date-time
                example: '2026-07-01T10:30:00.000Z'
              currency:
                type: string
                example: USD
              amount:
                type: number
                example: 0.01
              sourceBankInfo:
                $ref: '#/components/schemas/OnrampDepositTracking'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````