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

# Preview transfer

> **Validate and preview the transfer.**


---
Validates the transfer, calculates the relevant amount in crypto if requested amount was in fiat and updates
the current network fee values.


This endpoint uses the `NetworkId` field to specify which network will be used to perform the transfer. The target `NetworkId`
should be selected after configuring the transfer using `/configure` endpoint.



Returns the `PreviewId` value that can be used to commit the transfer.



## OpenAPI

````yaml post /api/v1/transfers/managed/preview
openapi: 3.0.1
info:
  title: Mesh Connect Integration API
  description: >-

    Mesh allows users to connect accounts of financial institutions,

    crypto exchanges, and self-custody wallets. Mesh handles credential

    validation, MFA, and error handling for each integration. After

    an account is connected, Mesh allows client applications to read holdings,

    transaction history and balances and execute crypto transfers (with user
    approval).
  version: '1.0'
servers:
  - url: https://integration-api.meshconnect.com
  - url: https://sandbox-integration-api.meshconnect.com
security:
  - Client-Secret: []
    Client-Id: []
tags:
  - name: BlockchainQuery
  - name: CatalogGasSponsorship
  - name: TokenNetworkPairs
  - name: RampKyc
  - name: RampPayment
  - name: RampSession
  - name: Integrations account information
  - name: Managed Account Authentication
    description: >-
      The recommended approach for account authentication. Front manages
      multiple authentication flows and handles all authentication steps such as
      MFA codes and OAuth redirect through our web and mobile SDKs.
  - name: Portfolio
    description: |


      ### Supported integrations:
      ```Robinhood```
      ```Coinbase```
      ```Kraken```
      ```CryptoCom```
      ```OpenSea```
      ```Binance```
      ```Gemini```
      ```OkCoin```
      ```KuCoin```
      ```CexIo```
      ```BinanceInternational```
      ```Bitstamp```
      ```GateIo```
      ```Okx```
      ```BitFlyer```
      ```Coinlist```
      ```Huobi```
      ```Bitfinex```
      ```KrakenDirect```
      ```BinanceInternationalDirect```
      ```BitfinexDirect```
      ```Bybit```
      ```Paxos```
      ```CoinbasePrime```
      ```BtcTurkDirect```
      ```KuCoinDirect```
      ```OkxOAuth```
      ```ParibuDirect```
      ```RobinhoodConnect```
      ```BlockchainCom```
      ```BitsoDirect```
      ```BinanceOAuth```
      ```BybitDirect```
      ```ParibuOAuth```
      ```BinanceTrDirect```
      ```BybitDirectMobile```
      ```Sandbox```
      ```Uphold```
      ```SandboxCoinbase```
      ```KrakenOAuth```
      ```BluvoKrakenOAuth```
      ```SandboxKrakenOAuth```
      ```DeFiWallet```
  - name: Balance
    description: |


      ### Supported integrations:
      ```Robinhood```
      ```Coinbase```
      ```Kraken```
      ```CryptoCom```
      ```Binance```
      ```Gemini```
      ```OkCoin```
      ```KuCoin```
      ```CexIo```
      ```BinanceInternational```
      ```Bitstamp```
      ```GateIo```
      ```Okx```
      ```BitFlyer```
      ```Coinlist```
      ```Huobi```
      ```Bitfinex```
      ```KrakenDirect```
      ```BinanceInternationalDirect```
      ```BitfinexDirect```
      ```Bybit```
      ```Paxos```
      ```CoinbasePrime```
      ```BtcTurkDirect```
      ```KuCoinDirect```
      ```OkxOAuth```
      ```ParibuDirect```
      ```RobinhoodConnect```
      ```BlockchainCom```
      ```BitsoDirect```
      ```BybitDirect```
      ```ParibuOAuth```
      ```BinanceTrDirect```
      ```BybitDirectMobile```
      ```Sandbox```
      ```Uphold```
      ```SandboxCoinbase```
      ```KrakenOAuth```
      ```BluvoKrakenOAuth```
      ```SandboxKrakenOAuth```
  - name: Transfers
    description: >


      ### Supported integrations:

      ```Robinhood```

      ```Coinbase```

      ```Kraken```

      ```CryptoCom```

      ```Binance```

      ```Gemini```

      ```OkCoin```

      ```KuCoin```

      ```BinanceInternational```

      ```Bitstamp```

      ```GateIo```

      ```Okx```

      ```Huobi```

      ```Bitfinex```

      ```KrakenDirect```

      ```BinanceInternationalDirect```

      ```BitfinexDirect```

      ```Bybit```

      ```Paxos```

      ```CoinbasePrime```

      ```BtcTurkDirect```

      ```ParibuDirect```

      ```RobinhoodConnect```

      ```BlockchainCom```

      ```BinanceConnect```

      ```RevolutConnect```

      ```BinancePay```

      ```BybitDirect```

      ```ParibuOAuth```

      ```PayPalConnect```

      ```CoinbaseRamp```

      ```BybitDirectMobile```

      ```Sandbox```

      ```CryptoComPay```

      ```Uphold```

      ```BinancePayOnchain```

      ```SandboxCoinbase```

      ```BybitPay```

      ```CashApp```

      ```SandboxKrakenOAuth```

      ```KrakPay```

      ```DeFiWallet```



      ### Integration-specific notes:



      #### Robinhood:



      Cryptocurrency transfers should be enabled in Robinhood settings.
      Transfers are disabled by default, enabling them for end users requires a
      review from Robinhood.


      Please note:
       * `MfaCode` parameter is required to initiate a transaction in Robinhood.
       * The user's security settings should be configured to use an authenticator application.
       * Robinhood doesn't allow initiation of transactions if the authenticator application is not configured.


      #### Coinbase:



      `MfaCode` parameter should be used to initiate transactions in Coinbase.
       * If the end user's Coinbase account is configured to use text messages (SMS) for two factor authentication, the API will return `MfaRequired` status, and a text code will then be sent by Coinbase. The code is expected to be provided in the subsequent call using the `MfaCode` request field
       * If the account is configured to use an authenticator application, the API is expecting to get the code in the `MfaCode` request field.


      #### Kraken:



      Kraken requires the explicit chain name to be provided (e.g. `Dogecoin` or
      `Ethereum (ERC20)`). The list of possible chains can be obtained by
      calling `symbol/details` endpoint.


      To initiate a transaction, a Kraken Address Key name should be provided in
      `TargetAddress` field. Target address should be added using Kraken UI,
      then its name should be used.



      #### Binance:



      `Enable Withdrawals` permission should be given to the user's API key to
      initiate transfers with Binance Us.


      Binance requires adding the IP address to the list of trusted IPs to be
      able to create API keys with transfer permission.
       * Please reach out to Front to get the static IP address. This address should be provided to the end user, and the user should be instructed to add it to the list of trusted IP addresses.
       * By default, the permission to enable withdrawals is turned off. If the end user's API key does not have the permission, asset transfers will not be available.


      #### KuCoin:



      KuCoin requires adding the IP address to the list of trusted IPs to be
      able to create API keys with transfer permission.


      `Fee` parameter should be used to initiate a transaction in KuCoin.


      Please note:
       * Please reach out to Front to get the static IP address. This address should be provided to the end user, and the user should be instructed to add it to the list of trusted IP addresses.
       * All currencies have their minimum `fee` and `amount` requirements. Please use `symbol/details` endpoint to get this data for a particular symbol.
       * KuCoin requires chain name to be provided for getting deposit address or initiating a cryptocurrency transfer. Some cryptocurrencies are supported over multiple chains. It's recommended to use `symbol/details` endpoint to get the list of supported chains and show it to the end user to select a target one.


      #### BinanceInternational:



      `Enable Withdrawals` permission should be given to the user's API key to
      initiate transfers with Binance International.


      Binance requires adding the IP address to the list of trusted IPs to be
      able to create API keys with transfer permission.
       * Please reach out to Front to get the static IP address. This address should be provided to the end user, and the user should be instructed to add it to the list of trusted IP addresses.
       * By default, the permission to enable withdrawals is turned off. If the end user's API key does not have the permission, asset transfers will not be available.


      #### GateIo:



      Gate.io requires adding IP address to the list of trusted IP addresses to
      be able to initiate a cryptocurrency transfers.


      Withdrawal address should be already verified or added on the Gate.io UI
      (in mobile application or on the web site).
       * Please reach out to Front to get the static IP address for withdrawals. This address should be provided to the end user, and the user should be instructed to add it to the list of trusted IP addresses.
       * Only verified withdrawal blockchain addresses are allowed for withdrawal with Gate.io API.
       * Gate.io requires chain name to be provided for getting deposit address or initiating a cryptocurrency transfer. Some cryptocurrencies are supported over multiple chains. It's recommended to use `symbol/details` endpoint to get the list of supported chains and show it to the end user to select a target one.


      #### Huobi:



      Warning: Huobi does not refund executed deposits that are below the
      `Minimum Deposit Amount`
       * Please check the MinimumDepositAmount in Get Deposit Address response in order to avoid making a deposit below the minimum amount
       * Huobi does not allow withdrawals to addresses that are not white-listed, please add the address that you would like to withdraw to the white list of addresses through the UI so that a withrawal can be processed


      #### Bitfinex:
       * The hash of transfer is not available when making a transfer in Bitfinex. To get the hash please re-query the transfer using the transaction id.
       * Bitfinex does not separate sub-accounts when returning the list of transfers.Therefore the same list of transfers is returned for all Bitfinex sub-accounts.


      #### KrakenDirect:



      Kraken requires the explicit chain name to be provided (e.g. `Dogecoin` or
      `Ethereum (ERC20)`). The list of possible chains can be obtained by
      calling `symbol/details` endpoint.


      To initiate a transaction, a Kraken Address Key name should be provided in
      `TargetAddress` field. Target address should be added using Kraken UI,
      then its name should be used.



      #### BitfinexDirect:
       * The hash of transfer is not available when making a transfer in Bitfinex. To get the hash please re-query the transfer using the transaction id.
       * Bitfinex does not separate sub-accounts when returning the list of transfers.Therefore the same list of transfers is returned for all Bitfinex sub-accounts.
  - name: Assets
  - name: Managed Transfers
  - name: Wallets
paths:
  /api/v1/transfers/managed/preview:
    post:
      tags:
        - Managed Transfers
      summary: Preview transfer
      description: "**Validate and preview the transfer.**\r\n\n\r\n---\r\nValidates the transfer, calculates the relevant amount in crypto if requested amount was in fiat and updates\r\nthe current network fee values.\r\n\n\r\nThis endpoint uses the `NetworkId` field to specify which network will be used to perform the transfer. The target `NetworkId`\r\nshould be selected after configuring the transfer using `/configure` endpoint.\r\n\n\n\r\nReturns the `PreviewId` value that can be used to commit the transfer."
      requestBody:
        content:
          application/json:
            schema:
              allOf:
                - $ref: '#/components/schemas/PreviewTransferRequest'
            examples:
              Preview with provided address:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amount: 10
              Preview with provided address, using fiat amount:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amountInFiat: 10
          text/json:
            schema:
              allOf:
                - $ref: '#/components/schemas/PreviewTransferRequest'
            examples:
              Preview with provided address:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amount: 10
              Preview with provided address, using fiat amount:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amountInFiat: 10
          application/*+json:
            schema:
              allOf:
                - $ref: '#/components/schemas/PreviewTransferRequest'
            examples:
              Preview with provided address:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amount: 10
              Preview with provided address, using fiat amount:
                value:
                  fromAuthToken: Secret authentication token
                  fromType: robinhood
                  networkId: 7436e9d0-ba42-4d2b-b4c0-8e4e606b2c12
                  symbol: USDT
                  toAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                  amountInFiat: 10
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PreviewTransferResponseApiResult'
              examples:
                Successful transfer preview:
                  value:
                    content:
                      status: succeeded
                      previewResult:
                        previewId: 29b185b1-2305-40fb-a0e2-929d61451568
                        previewExpiresIn: 300
                        fromAddress: '0x9Bf6207f8A3f4278E0C989527015deFe10e5D7c6'
                        toAddress: '0x326a8825472bb0f4719998e708a1eeeb4473ed1b'
                        symbol: USDT
                        amount: 10
                        amountInFiat: 10
                        totalEstimatedAmount: 11.21
                        totalEstimatedAmountInFiat: 11.21
                        networkId: e3c7fdd8-b1fc-4e51-85ae-bb276e075611
                        institutionTransferFee:
                          fee: 0
                          feeCurrency: USDT
                          feeInFiat: 0
                          feeInTransferCurrency: 0
                        estimatedNetworkGasFee:
                          fee: 1.1
                          feeCurrency: USDT
                          feeInFiat: 1.1
                          feeInTransferCurrency: 0
                        unitPrice: 0
                        customClientFee:
                          fee: 0.011
                          feeCurrency: USDT
                          feeInFiat: 0.011
                          feeInTransferCurrency: 0
                        transferType: deposit
                        isCustomClientFeeProvided: false
                        amountWithCustomClientFee: '0'
                        isFeeIncluded: false
                        amountToReceive: 0
                        amountToReceiveInFiat: 0
                        transferAmountToRequest: 0
                        isMaximumAmount: false
                        isBridging: false
                        totalEstimatedAmountPlusConversionFeesInFiat: 0
                        brokerType: robinhood
                    status: ok
                    message: ''
                    errorHash: 69ede01c
                    teamCode: P4
                    errorType: ''
                Failed transfer preview:
                  value:
                    status: badRequest
                    message: "The\_specified amount is greater than the maximum amount allowed."
                    displayMessage: "The\_specified amount is greater than the maximum amount allowed."
                    errorHash: 160cb7f0
                    teamCode: P4
                    errorType: invalidField
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiResult'
              example:
                status: badRequest
                message: Error message
                displayMessage: Optional display message
                errorHash: 7dcbb73d
                teamCode: P4
                errorType: missingField
        '401':
          description: Unauthorized
          content:
            application/json:
              schema: {}
        '403':
          description: >-
            The API key used does not have write permission to call this Mesh
            endpoint.
          content:
            application/json:
              schema: {}
components:
  schemas:
    PreviewTransferRequest:
      required:
        - fromAuthToken
        - fromType
      type: object
      properties:
        fromAuthToken:
          minLength: 1
          type: string
          description: The authentication token to send the asset from.
        fromType:
          enum:
            - robinhood
            - eTrade
            - alpaca
            - tdAmeritrade
            - weBull
            - stash
            - interactiveBrokers
            - public
            - coinbase
            - kraken
            - coinbasePro
            - cryptoCom
            - openSea
            - binanceUs
            - gemini
            - cryptocurrencyAddress
            - cryptocurrencyWallet
            - okCoin
            - bittrex
            - kuCoin
            - etoro
            - cexIo
            - binanceInternational
            - bitstamp
            - gateIo
            - acorns
            - okx
            - bitFlyer
            - coinlist
            - huobi
            - bitfinex
            - deFiWallet
            - krakenDirect
            - vanguard
            - binanceInternationalDirect
            - bitfinexDirect
            - bybit
            - paxos
            - coinbasePrime
            - btcTurkDirect
            - kuCoinDirect
            - okxOAuth
            - paribuDirect
            - robinhoodConnect
            - blockchainCom
            - bitsoDirect
            - binanceConnect
            - binanceOAuth
            - revolutConnect
            - binancePay
            - bybitDirect
            - paribuOAuth
            - payPalConnect
            - binanceTrDirect
            - coinbaseRamp
            - bybitDirectMobile
            - sandbox
            - cryptoComPay
            - bybitEuDirect
            - uphold
            - binancePayOnchain
            - sandboxCoinbase
            - bybitPay
            - krakenOAuth
            - bluvoKrakenOAuth
            - cashApp
            - sandboxKrakenOAuth
            - krakPay
            - unlimit
            - alchemyPay
            - okxPay
          allOf:
            - $ref: '#/components/schemas/BrokerType'
          description: The type of the integration to send the asset from.
        networkId:
          type: string
          description: The network to send the asset over.
          format: uuid
        symbol:
          type: string
          description: The symbol of the digital asset to send.
          nullable: true
        toAddress:
          type: string
          description: The target address to send the asset to.
          nullable: true
        addressTag:
          type: string
          description: Secondary address identifier for coins like XRP,XMR etc.
          nullable: true
        amount:
          type: number
          description: The amount to send, in crypto.
          format: double
          nullable: true
        amountInFiat:
          type: number
          description: >-
            The amount to send, in fiat currency. Can be used alternatively to
            `Amount`.
          format: double
          nullable: true
        fiatCurrency:
          type: string
          description: >-
            Fiat currency that is to get corresponding converted fiat values of
            transfer and fee amounts. If not provided, defaults to `USD`.
          nullable: true
        transactionId:
          maxLength: 128
          minLength: 0
          type: string
          description: >-
            Transaction ID Provided by client to track transaction in future
            calls.
          nullable: true
        bridgingRouteType:
          allOf:
            - $ref: '#/components/schemas/BridgingRouteType'
          description: "Specifies whether the transfer is a bridge (cross-chain) or a swap (same-chain).\r\nNull = vanilla deposit. Replaces the legacy Org.Front.Core.Contracts.Models.Brokers.B2B.ManagedTransfers.BasePreviewTransferRequest.IsBridging flag."
          nullable: true
        isBridging:
          type: boolean
          description: Indicates that the transfer is a bridging transfer.
          nullable: true
        bridgingDirectionId:
          type: string
          description: >-
            The ID of the bridging direction configuration to use for this
            transfer.
          format: uuid
          nullable: true
        isAtomicBatchTxAvailable:
          type: boolean
          description: Specifies if connected wallet supports batched transactions.
          nullable: true
        isInclusiveFeeEnabled:
          type: boolean
          description: Specifies if all the fees are included in the amount to transfer.
      additionalProperties: false
    PreviewTransferResponseApiResult:
      type: object
      properties:
        status:
          enum:
            - ok
            - serverFailure
            - permissionDenied
            - badRequest
            - notFound
            - conflict
            - tooManyRequest
            - locked
            - unavailableForLegalReasons
          allOf:
            - $ref: '#/components/schemas/ApiResultStatus'
          readOnly: true
        message:
          type: string
          description: A message generated by the API
          nullable: true
        displayMessage:
          type: string
          description: User-friendly display message that can be presented to the end user
          nullable: true
        errorHash:
          type: string
          description: >-
            An error grouping hash from string components and caller
            information. Used by bugsnag on FE for correct error grouping
          nullable: true
          readOnly: true
        teamCode:
          type: string
          description: "Opaque team code for error routing. Resolved from exception origin or caller file path via CODEOWNERS.\r\nFormat: 2-character code (e.g., \"7K\", \"M2\"). Use for alerting/routing, not display."
          nullable: true
          readOnly: true
        errorType:
          type: string
          description: "Strictly-typed error type that is explaining the reason of an unsuccessful status of the operation.\r\nAll possible error types are available in the documentation."
          nullable: true
        errorData:
          nullable: true
          readOnly: true
        content:
          allOf:
            - $ref: '#/components/schemas/PreviewTransferResponse'
          nullable: true
      additionalProperties: false
    ApiResult:
      type: object
      properties:
        status:
          enum:
            - ok
            - serverFailure
            - permissionDenied
            - badRequest
            - notFound
            - conflict
            - tooManyRequest
            - locked
            - unavailableForLegalReasons
          allOf:
            - $ref: '#/components/schemas/ApiResultStatus'
          readOnly: true
        message:
          type: string
          description: A message generated by the API
          nullable: true
        displayMessage:
          type: string
          description: User-friendly display message that can be presented to the end user
          nullable: true
        errorHash:
          type: string
          description: >-
            An error grouping hash from string components and caller
            information. Used by bugsnag on FE for correct error grouping
          nullable: true
          readOnly: true
        teamCode:
          type: string
          description: "Opaque team code for error routing. Resolved from exception origin or caller file path via CODEOWNERS.\r\nFormat: 2-character code (e.g., \"7K\", \"M2\"). Use for alerting/routing, not display."
          nullable: true
          readOnly: true
        errorType:
          type: string
          description: "Strictly-typed error type that is explaining the reason of an unsuccessful status of the operation.\r\nAll possible error types are available in the documentation."
          nullable: true
        errorData:
          nullable: true
          readOnly: true
      additionalProperties: false
    BrokerType:
      enum:
        - robinhood
        - eTrade
        - alpaca
        - tdAmeritrade
        - weBull
        - stash
        - interactiveBrokers
        - public
        - coinbase
        - kraken
        - coinbasePro
        - cryptoCom
        - openSea
        - binanceUs
        - gemini
        - cryptocurrencyAddress
        - cryptocurrencyWallet
        - okCoin
        - bittrex
        - kuCoin
        - etoro
        - cexIo
        - binanceInternational
        - bitstamp
        - gateIo
        - acorns
        - okx
        - bitFlyer
        - coinlist
        - huobi
        - bitfinex
        - deFiWallet
        - krakenDirect
        - vanguard
        - binanceInternationalDirect
        - bitfinexDirect
        - bybit
        - paxos
        - coinbasePrime
        - btcTurkDirect
        - kuCoinDirect
        - okxOAuth
        - paribuDirect
        - robinhoodConnect
        - blockchainCom
        - bitsoDirect
        - binanceConnect
        - binanceOAuth
        - revolutConnect
        - binancePay
        - bybitDirect
        - paribuOAuth
        - payPalConnect
        - binanceTrDirect
        - coinbaseRamp
        - bybitDirectMobile
        - sandbox
        - cryptoComPay
        - bybitEuDirect
        - uphold
        - binancePayOnchain
        - sandboxCoinbase
        - bybitPay
        - krakenOAuth
        - bluvoKrakenOAuth
        - cashApp
        - sandboxKrakenOAuth
        - krakPay
        - unlimit
        - alchemyPay
        - okxPay
      type: string
    BridgingRouteType:
      enum:
        - bridge
        - swap
        - direct
      type: string
      description: "Classifies a transfer route as a cross-chain bridge or a same-chain swap.\r\nReplaces the legacy `IsBridging*` boolean flags. Null indicates a vanilla\r\nsame-chain deposit (neither bridge nor swap)."
    ApiResultStatus:
      enum:
        - ok
        - serverFailure
        - permissionDenied
        - badRequest
        - notFound
        - conflict
        - tooManyRequest
        - locked
        - unavailableForLegalReasons
      type: string
    PreviewTransferResponse:
      type: object
      properties:
        status:
          enum:
            - succeeded
            - failed
            - requiresFunding
          allOf:
            - $ref: '#/components/schemas/PreviewTransferStatus'
          description: The status of the operation.
        previewResult:
          allOf:
            - $ref: '#/components/schemas/PreviewTransferResult'
          description: Result of the preview.
          nullable: true
        transferBalanceFundingAvailability:
          allOf:
            - $ref: '#/components/schemas/TransferBalanceFundingAvailability'
          nullable: true
        transferFromAnotherAccountAvailabilityInfo:
          allOf:
            - $ref: '#/components/schemas/TransferFromAnotherAccountAvailabilityInfo'
          description: >-
            For instance if not enough assets in Spot account, and we can fill
            it from Funding account
          nullable: true
      additionalProperties: false
    PreviewTransferStatus:
      enum:
        - succeeded
        - failed
        - requiresFunding
      type: string
    PreviewTransferResult:
      type: object
      properties:
        previewId:
          type: string
          description: >-
            The Id of the preview of the transfer. Should be used to commit the
            transfer using `Execute` endpoint.
          format: uuid
          nullable: true
        previewExpiresIn:
          type: integer
          description: >-
            The period of time in seconds during which the transfer can be
            committed.
          format: int32
        fromAddress:
          type: string
          description: >-
            Obtained address that will be used to send the transfer. Not
            guaranteed to be returned by some of integrations.
          nullable: true
        refundAddress:
          type: string
          description: >-
            Obtained address that will be used to refund the transfer. Not
            guaranteed to be returned by some integrations.
          nullable: true
        refundAddressTag:
          type: string
          description: >-
            Obtained secondary address identifier for coins like XRP, XMR etc
            that will be used to refund the transfer. Not guaranteed to be
            returned by some integrations.
          nullable: true
        toAddress:
          type: string
          description: The target address to send the asset to.
          nullable: true
        addressTag:
          type: string
          description: Secondary address identifier for coins like XRP, XMR etc.
          nullable: true
        symbol:
          type: string
          description: Symbol of the asset to be sent.
          nullable: true
        amount:
          type: number
          description: "Amount in symbol. If the transfer was requested using `AmountInFiat` field, this field represents the exact amount\r\nof the asset that will be transferred."
          format: double
        amountInFiat:
          type: number
          description: "Transfer amount in fiat. If the transfer was requested in crypto amount using the `Amount` field,\r\nthis field contains the corresponding converted to fiat value."
          format: double
        totalEstimatedAmount:
          type: number
          description: >-
            Total estimated amount of the transfer including all fees, in
            cryptocurrency.
          format: double
        totalEstimatedAmountInFiat:
          type: number
          description: >-
            Total estimated amount of the transfer including all fees, converted
            to fiat.
          format: double
        networkId:
          type: string
          description: Id of the network in Front system.
          format: uuid
        networkName:
          type: string
          description: Name of the network in Front system.
          nullable: true
        contractAddress:
          type: string
          description: Blockchain address of the transferred token's contract
          nullable: true
        institutionTransferFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: "The fee that is taken by the institution. Depending on the institution, can cover the gas fee. Some institutions do not\r\ntake the transfer fee and only network fee is used for the transfer."
          nullable: true
        estimatedNetworkGasFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: "The gas fee that is estimated to be taken by the network. Depending on the integration, the network gas fee might be\r\ncovered by the `InstitutionTransferFee`."
          nullable: true
        estimatedATARentFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: "The rent fee that is estimated to be required for creating an Associated Token Account (ATA) on Solana.\r\nThis fee is separate from the transaction/gas fee and is only required when the receiver doesn't have an ATA for the token."
          nullable: true
        estimatedGasFeeForDisplay:
          allOf:
            - $ref: '#/components/schemas/EstimatedGasFeeForDisplay'
          description: "Combined display of estimated gas fees including network gas fee and ATA rent fee (if applicable).\r\nThis provides a consolidated view of all gas-related fees for display purposes."
          nullable: true
        estimatedNetworkGasFeeDetails:
          allOf:
            - $ref: '#/components/schemas/TransferFeeDetails'
          description: >-
            The gas fee values in EIP 1559 standard that is estimated to be
            taken by the network.
          nullable: true
        decimalPlaces:
          type: integer
          description: Number of decimal places used to represent the token's smallest unit
          format: int32
          nullable: true
        unitPrice:
          type: number
          description: The price of the cryptocurrency asset in the fiat currency.
          format: double
        clientTransactionId:
          maxLength: 128
          minLength: 0
          type: string
          description: Transaction id provided by the client
          nullable: true
        userId:
          type: string
          description: The end user identifier associated with the transfer.
          nullable: true
        clientFee:
          maximum: 1
          minimum: 0
          type: number
          description: "A percentage fee (input as a ratio, eg. 0.02500 = 2.500%) added onto your users' gross payments.\r\nThis will override any default fee entered in your Mesh dashboard for an individual transaction.\r\nPlease note: this fee should only be used for Payments (when the transfer destination is an address owned by your company),\r\nand not for Deposits (when the transfer destination is an address owned by the end user).\r\nIf used for Deposits, it will increase the size of the user's Deposit by the fee amount,\r\nbut will incorrectly show to the user as a fee."
          format: double
          nullable: true
        customClientFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: >-
            The client fee that is estimated to be added to the total estimated
            transfer amount, based on the user's requested transfer amount and
            client fee percentage.
          nullable: true
        processingFeeRetainMethod:
          allOf:
            - $ref: '#/components/schemas/ProcessingFeeRetainMethod'
          nullable: true
        transferType:
          enum:
            - deposit
            - payment
            - onramp
            - fiatOnRamp
            - fiatOffRamp
          allOf:
            - $ref: '#/components/schemas/TransferTypeEnum'
          description: "Deposit: The user is transferring crypto to a wallet they own on your platform.\r\nPayment: The user is transferring crypto to a wallet your company owns in exchange for receiving a good or service.\r\nOnramp: The user is using balances and linked payment methods in an exchange account to fund the purchase of crypto in their wallet on your platform."
        isCustomClientFeeProvided:
          type: boolean
        amountWithCustomClientFee:
          type: number
          description: "Amount in symbol after the client fees are applied. This field represents the exact amount\r\nof the asset that will be requested for transfer."
          format: double
        isFeeIncluded:
          type: boolean
          description: "Indicates if all the fees are included in the amount. For example, if this field's value is `true`\r\nand the user wants to send 1 BTC and the sum of all fees is 0.1 BTC, the user will be charged 1 BTC, and\r\nthe target address will receive 0.9 BTC.\r\nIf the fees are no inclusive, the user will be charged 1.1 BTC and the target address will receive 1 BTC."
        amountToReceive:
          type: number
          description: "Indicates the final amount to receive after all fees are applied. In case fees are not inclusive (`IsFeeIncluded` is `false`),\r\nthis field will be equal to the `Amount` field."
          format: double
        amountToReceiveInFiat:
          type: number
          description: "Indicates the final amount in fiat to receive after all fees are applied. In case fees are not inclusive (`IsFeeIncluded` is `false`),\r\nthis field will be equal to the `AmountInFiat` field."
          format: double
        transferAmountToRequest:
          type: number
          description: >-
            Exact amount in cryptocurrency requested to transfer to the
            destination address using the target integration.
          format: double
        isMaximumAmount:
          type: boolean
          description: >-
            Indicates if the transfer's intention is to transfer all available
            assets using the requested network and symbol.
        fiatCurrency:
          type: string
          description: >-
            Indicates the fiat currency that is used to calculate transfer
            amounts.
          nullable: true
        bridgingRouteType:
          allOf:
            - $ref: '#/components/schemas/BridgingRouteType'
          description: "Bridge or swap classification for this transfer. Null = vanilla deposit.\r\nReplaces the legacy Org.Front.Core.Contracts.Models.Brokers.B2B.ManagedTransfers.PreviewTransferResult.IsBridging flag."
          nullable: true
        isBridging:
          type: boolean
          description: Indicates if the transfer is a bridging transfer (cross-chain).
        relayFeeRetainType:
          allOf:
            - $ref: '#/components/schemas/ProcessingFeeRetainType'
          description: "Set to Relay when an app-fee is being captured on this transfer via the Relay provider.\r\nCurrently flagged for Relay bridging previews; future work will extend this to vanilla\r\n(non-bridging) transfers routed through Relay solely for fee capture."
          nullable: true
        bridgingDetails:
          allOf:
            - $ref: '#/components/schemas/BridgingDetails'
          description: >-
            Details of the bridging operation, in case the transfer is a
            bridging transfer.
          nullable: true
        totalEstimatedAmountPlusConversionFeesInFiat:
          type: number
          description: >-
            Total amount of the transfer including all fees (include smart
            funding conversion fees), converted to fiat.
          format: double
        brokerType:
          enum:
            - robinhood
            - eTrade
            - alpaca
            - tdAmeritrade
            - weBull
            - stash
            - interactiveBrokers
            - public
            - coinbase
            - kraken
            - coinbasePro
            - cryptoCom
            - openSea
            - binanceUs
            - gemini
            - cryptocurrencyAddress
            - cryptocurrencyWallet
            - okCoin
            - bittrex
            - kuCoin
            - etoro
            - cexIo
            - binanceInternational
            - bitstamp
            - gateIo
            - acorns
            - okx
            - bitFlyer
            - coinlist
            - huobi
            - bitfinex
            - deFiWallet
            - krakenDirect
            - vanguard
            - binanceInternationalDirect
            - bitfinexDirect
            - bybit
            - paxos
            - coinbasePrime
            - btcTurkDirect
            - kuCoinDirect
            - okxOAuth
            - paribuDirect
            - robinhoodConnect
            - blockchainCom
            - bitsoDirect
            - binanceConnect
            - binanceOAuth
            - revolutConnect
            - binancePay
            - bybitDirect
            - paribuOAuth
            - payPalConnect
            - binanceTrDirect
            - coinbaseRamp
            - bybitDirectMobile
            - sandbox
            - cryptoComPay
            - bybitEuDirect
            - uphold
            - binancePayOnchain
            - sandboxCoinbase
            - bybitPay
            - krakenOAuth
            - bluvoKrakenOAuth
            - cashApp
            - sandboxKrakenOAuth
            - krakPay
            - unlimit
            - alchemyPay
            - okxPay
          allOf:
            - $ref: '#/components/schemas/BrokerType'
          description: >-
            Bridging quote from DeFi bridging service when direct transfer is
            not possible.
        sessionId:
          type: string
          description: The Id of the session initiated by user.
          format: uuid
          nullable: true
        sponsorshipSelection:
          allOf:
            - $ref: '#/components/schemas/SponsorshipSelection'
          description: "Gas-sponsorship selector verdict for this preview. Populated only when a sponsorship\r\nstrategy was actually applied - null when the user pays native gas directly or when\r\nthe source/route is not eligible (CeFi, bridging)"
          nullable: true
      additionalProperties: false
    TransferBalanceFundingAvailability:
      type: object
      properties:
        status:
          enum:
            - disabled
            - available
            - requiresAmountLowering
            - notApplicable
            - unavailable
          allOf:
            - $ref: '#/components/schemas/TransferBalanceFundingAvailabilityStatus'
        transferTotalAmount:
          type: number
          description: The total transfer amount in crypto after all fees are applied
          format: double
        unitPrice:
          type: number
          description: The price of the cryptocurrency asset in the fiat currency.
          format: double
        gasFeeBuffer:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: Represents the safety margin amount to cover gas fee volatility.
          nullable: true
        symbol:
          type: string
          nullable: true
        transferTotalAmountInFiat:
          type: number
          description: The total transfer amount in fiat after all fees are applied.
          format: double
      additionalProperties: false
    TransferFromAnotherAccountAvailabilityInfo:
      type: object
      properties:
        transferFromAnotherAccountNeeded:
          type: boolean
        transferFromAnotherAccountAmount:
          type: number
          format: double
        anotherAccountName:
          type: string
          nullable: true
      additionalProperties: false
    TransferFee:
      type: object
      properties:
        fee:
          type: number
          description: The amount of the fee.
          format: double
        feeCurrency:
          type: string
          description: >-
            The currency of the fee. Does not match the currency of the transfer
            in some cases.
          nullable: true
        feeInFiat:
          type: number
          description: The value of the fee converted to the fiat currency.
          format: double
        feeInTransferCurrency:
          type: number
          description: The value of the fee converted to the transfer currency.
          format: double
      additionalProperties: false
    EstimatedGasFeeForDisplay:
      type: object
      properties:
        amount:
          type: number
          description: "Total estimated fee amount. Includes network gas fee, ATA rent fee (if applicable),\r\nOnly fees in the same currency as the network gas fee are included in the crypto amount."
          format: double
        symbol:
          type: string
          description: >-
            The currency symbol of the base fee (typically the network gas fee
            currency, e.g., "SOL").
          nullable: true
        amountInFiat:
          type: number
          description: "Total estimated fee amount converted to fiat currency. Includes all applicable fees\r\n(network gas fee, ATA rent fee) regardless of currency."
          format: double
        includes:
          type: array
          items:
            $ref: '#/components/schemas/EstimatedGasFeeType'
          description: >-
            List of fee types included in this estimate. Can include:
            EstimatedNetworkGasFee, EstimatedAtaRentFee
          nullable: true
      additionalProperties: false
    TransferFeeDetails:
      type: object
      properties:
        gasLimit:
          type: number
          description: Units of gas used
          format: double
          nullable: true
        maxPriorityFeePerGas:
          type: number
          description: The max amount of tip to be paid to validator
          format: double
          nullable: true
        maxFeePerGas:
          type: number
          description: The max amount of fee to be paid per gas
          format: double
          nullable: true
      additionalProperties: false
    ProcessingFeeRetainMethod:
      type: object
      properties:
        type:
          enum:
            - default
            - smartDeposit
            - relay
          allOf:
            - $ref: '#/components/schemas/ProcessingFeeRetainType'
        processingFeeAddress:
          type: string
          nullable: true
      additionalProperties: false
    TransferTypeEnum:
      enum:
        - deposit
        - payment
        - onramp
        - fiatOnRamp
        - fiatOffRamp
      type: string
    ProcessingFeeRetainType:
      enum:
        - default
        - smartDeposit
        - relay
      type: string
    BridgingDetails:
      type: object
      properties:
        bridgingType:
          enum:
            - offChain
            - onChain
          allOf:
            - $ref: '#/components/schemas/BridgingType'
          description: >-
            Indicates if the transfer is a bridging transfer, meaning that the
            transfer will be swapped between two different networks.
        bridgingDirectionId:
          type: string
          description: >-
            The ID of the bridging direction that was used to generate the
            preview.
          format: uuid
        targetAddress:
          type: string
          nullable: true
        destinationSymbol:
          type: string
          nullable: true
        destinationNetwork:
          type: string
          nullable: true
        providerType:
          enum:
            - bridgeXyz
            - bvnk
            - relay
            - liFi
          allOf:
            - $ref: '#/components/schemas/BridgingProviderType'
        totalBridgingFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          nullable: true
        appFee:
          allOf:
            - $ref: '#/components/schemas/TransferFee'
          description: "Mesh retention (Relay app fee). Null when fee retention is not configured for the\r\nclient/transfer type. Surfaced separately from Org.Front.Core.Contracts.Models.Bridging.BridgingDetails.TotalBridgingFee because\r\nRelay excludes the app fee from FeeSummary totals — MaxAmount math must subtract it on\r\ntop of Org.Front.Core.Contracts.Models.Bridging.BridgingDetails.TotalBridgingFee."
          nullable: true
        rate:
          type: number
          format: double
        amountOut:
          type: number
          format: double
        referrerId:
          type: string
          description: "The unique referrer ID generated for this bridging operation, sent to the Relay provider for tracking.\r\nUsed to identify and track the transaction on Relay's side during polling."
          nullable: true
      additionalProperties: false
    SponsorshipSelection:
      type: object
      properties:
        strategyKind:
          allOf:
            - $ref: '#/components/schemas/GasSponsorshipStrategyKind'
          description: The chosen strategy, or null when no strategy was selected.
          nullable: true
        verdict:
          allOf:
            - $ref: '#/components/schemas/EligibilityVerdict'
          description: The verdict that produced this selection.
          nullable: true
        hasStrategy:
          type: boolean
          description: >-
            True when a strategy was chosen and is willing to sponsor the
            transfer.
          readOnly: true
      additionalProperties: false
      description: "The selector's final decision for a single eligibility evaluation. Either:\r\n<list type=\"bullet\"><item>A strategy was chosen (Org.Front.Core.Contracts.GasSponsorship.SponsorshipSelection.StrategyKind has a value and Org.Front.Core.Contracts.GasSponsorship.SponsorshipSelection.Verdict.Eligible is true), or</item><item>No strategy applies (Org.Front.Core.Contracts.GasSponsorship.SponsorshipSelection.StrategyKind is null; Org.Front.Core.Contracts.GasSponsorship.SponsorshipSelection.Verdict carries the rejection reason).</item></list>\r\nPersisted on `TransferPreview.TransferGasFeePayerId` (via the related `TransferGasFeePayer`\r\nrow) so downstream calls (`/v1/sponsorship/build`, `/register`) all agree on the\r\nsame choice even if state shifts between calls."
    TransferBalanceFundingAvailabilityStatus:
      enum:
        - disabled
        - available
        - requiresAmountLowering
        - notApplicable
        - unavailable
      type: string
    EstimatedGasFeeType:
      enum:
        - estimatedNetworkGasFee
        - estimatedAtaRentFee
      type: string
      description: >-
        Fee types that can be included in EstimatedGasFeeForDisplay.Includes
        array.
    BridgingType:
      enum:
        - offChain
        - onChain
      type: string
    BridgingProviderType:
      enum:
        - bridgeXyz
        - bvnk
        - relay
        - liFi
      type: string
    GasSponsorshipStrategyKind:
      enum:
        - unknown
        - metaMaskGasIncluded
        - alchemySolanaFeePayer
        - relayLinkEvmFeeSponsor
      type: string
      description: "Identifies a concrete gas sponsorship strategy. Used as the keyed-services DI key for\r\n`IGasSponsorshipStrategy` registrations, persisted on\r\n`ClientGasSponsorshipPolicy.StrategyOrder`"
    EligibilityVerdict:
      type: object
      properties:
        eligible:
          type: boolean
        reason:
          enum:
            - unknown
            - eligible
            - killSwitchOff
            - noPolicyConfigured
            - notNeeded
            - noStrategyEligible
            - perStrategyKillSwitchOff
            - brokerTypeMismatch
            - tokenNotAllowlisted
            - insufficientGasPaymentBalance
            - tokenExtensionUnsupported
            - walletNotInAllowlist
            - routeTypeUnsupported
          allOf:
            - $ref: '#/components/schemas/EligibilityReason'
          description: "Explains why the gas-sponsorship selector or an individual strategy returned its verdict.\r\nSurfaced in Datadog telemetry tags (`gas_sponsorship.selector.{eligible|ineligible}`)\r\nand on `GasSponsorshipLedgerEntry` rows for post-hoc analysis. Numeric values are\r\npart of the telemetry contract — do not renumber."
        gasPaymentToken:
          type: string
          nullable: true
      additionalProperties: false
      description: "The outcome of an `IGasSponsorshipStrategy.EvaluateEligibilityAsync` call, returned to\r\nthe selector. Always emitted to telemetry — both Org.Front.Core.Contracts.GasSponsorship.EligibilityVerdict.Eligible and ineligible\r\noutcomes are useful for understanding conversion impact."
    EligibilityReason:
      enum:
        - unknown
        - eligible
        - killSwitchOff
        - noPolicyConfigured
        - notNeeded
        - noStrategyEligible
        - perStrategyKillSwitchOff
        - brokerTypeMismatch
        - tokenNotAllowlisted
        - insufficientGasPaymentBalance
        - tokenExtensionUnsupported
        - walletNotInAllowlist
        - routeTypeUnsupported
      type: string
      description: "Explains why the gas-sponsorship selector or an individual strategy returned its verdict.\r\nSurfaced in Datadog telemetry tags (`gas_sponsorship.selector.{eligible|ineligible}`)\r\nand on `GasSponsorshipLedgerEntry` rows for post-hoc analysis. Numeric values are\r\npart of the telemetry contract — do not renumber."
  securitySchemes:
    Client-Secret:
      type: apiKey
      description: Contact Mesh to get client Secret
      name: X-Client-Secret
      in: header
    Client-Id:
      type: apiKey
      description: Contact Mesh to get client Id
      name: X-Client-Id
      in: header

````