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

# Get approve info

> This endpoint determines whether a token approval is required on the specified blockchain. If approval is needed, it returns all transaction data required to execute the approval on-chain.



## OpenAPI

````yaml https://api-v2.rubic.exchange/api/routes/swagger-json get /api/utility/checkApprove
openapi: 3.0.0
info:
  title: Rubic API
  description: The Rubic API description
  version: '1.0'
  contact: {}
servers:
  - url: https://api-v2.rubic.exchange
    description: Production
security: []
tags: []
paths:
  /api/utility/checkApprove:
    get:
      tags:
        - Utility
      summary: Get approve info
      description: >-
        This endpoint determines whether a token approval is required on the
        specified blockchain. If approval is needed, it returns all transaction
        data required to execute the approval on-chain.
      operationId: UtilsController_checkApprove
      parameters:
        - name: blockchain
          required: true
          in: query
          description: Blockchain name
          schema:
            enum:
              - MUMBAI
              - BSCT
              - GOERLI
              - FUJI
              - SCROLL_SEPOLIA
              - ARTHERA
              - SEPOLIA
              - BERACHAIN_TESTNET
              - BLAST_TESTNET
              - HOLESKY
              - UNICHAIN_SEPOLIA_TESTNET
              - ETH
              - BSC
              - POLYGON
              - POLYGON_ZKEVM
              - AVALANCHE
              - MOONRIVER
              - FANTOM
              - HARMONY
              - ARBITRUM
              - AURORA
              - TELOS
              - OPTIMISM
              - CRONOS
              - OKX
              - GNOSIS
              - FUSE
              - MOONBEAM
              - CELO
              - BOBA
              - BOBA_BSC
              - ASTAR_EVM
              - KAVA
              - BITGERT
              - OASIS
              - METIS
              - DEFIKINGDOMS
              - KLAYTN
              - VELAS
              - SYSCOIN
              - ETHEREUM_CLASSIC
              - FLARE
              - IOTEX
              - THETA
              - ZK_SYNC
              - PULSECHAIN
              - LINEA
              - BASE
              - MANTLE
              - MANTA_PACIFIC
              - SCROLL
              - ZETACHAIN
              - BLAST
              - HORIZEN_EON
              - MERLIN
              - ROOTSTOCK
              - MODE
              - ZK_FAIR
              - ZK_LINK
              - XLAYER
              - TAIKO
              - SEI
              - CORE
              - BAHAMUT
              - BITLAYER
              - GRAVITY
              - FRAXTAL
              - BERACHAIN
              - SONEIUM
              - UNICHAIN
              - MORPH
              - HEMI
              - PLASMA
              - MONAD
              - HYPER_EVM
              - MEGAETH
              - BITCOIN_CASH
              - NEAR
              - ICP
              - CARDANO
              - AION
              - ALGORAND
              - APTOS
              - ARDOR
              - ARK
              - ASTAR
              - COSMOS
              - BAND_PROTOCOL
              - BITCOIN_DIAMOND
              - BSV
              - BITCOIN_GOLD
              - CASPER
              - DASH
              - DECRED
              - DIGI_BYTE
              - DIVI
              - DOGECOIN
              - POLKADOT
              - MULTIVERS_X
              - FIO_PROTOCOL
              - FIRO
              - FLOW
              - HEDERA
              - HELIUM
              - ICON
              - IOST
              - IOTA
              - KADENA
              - KOMODO
              - KUSAMA
              - LISK
              - LITECOIN
              - TERRA
              - TERRA_CLASSIC
              - MINA_PROTOCOL
              - NANO
              - NEO
              - OSMOSIS
              - PIVX
              - POLYX
              - QTUM
              - THOR_CHAIN
              - RAVENCOIN
              - SIA
              - SECRET
              - STEEM
              - STRATIS
              - STACKS
              - SOLAR
              - VE_CHAIN
              - WAVES
              - WAX
              - DX_CHAIN
              - E_CASH
              - NEM
              - STELLAR
              - MONERO
              - RIPPLE
              - TEZOS
              - VERGE
              - SYMBOL
              - ZCASH
              - HORIZEN
              - ZILLIQA
              - KAVA_COSMOS
              - FILECOIN
              - EOS
              - ONTOLOGY
              - XDC
              - STARKNET
              - TON
              - SOLANA
              - BITCOIN
              - TRON
              - SUI
            type: string
        - name: tokenAddress
          required: true
          in: query
          description: Address of ERC20 token
          schema:
            type: string
        - name: walletAddress
          required: true
          in: query
          description: Owner wallet address
          schema:
            type: string
        - name: spenderAddress
          required: true
          in: query
          description: Address of spender contract
          schema:
            type: string
        - name: amount
          required: true
          in: query
          description: Non wei amount for approve
          schema:
            example: 10.5
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApproveResponseDto'
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApproveResponseDto'
components:
  schemas:
    ApproveResponseDto:
      type: object
      properties:
        needApprove:
          type: boolean
          description: is approve needed
        transaction:
          description: >-
            Transaction body for approve call in web3, if approve is needed.
            Otherwise this field is undefined
          allOf:
            - $ref: '#/components/schemas/TransactionDto'
        message:
          type: string
          description: Meaning of response
      required:
        - needApprove
        - message
    TransactionDto:
      type: object
      properties:
        approvalAddress:
          type: string
          description: Gateway address to approve erc20 token
        permit2Address:
          type: string
          description: ''
        data:
          type: string
          description: Data to execute
        to:
          type: string
          description: Contract to call
        value:
          type: string
          description: ''
        depositAddress:
          type: string
          description: Address to deposit funds to
        amountToSend:
          type: string
          description: Token amount to send to deposit address
        extraFields:
          type: object
          description: Extra fields to perform the transaction
        exchangeId:
          type: string
          description: ''
        tonMessages:
          description: Messages array for tonConnectUI.sendTransaction() call
          type: array
          items:
            $ref: '#/components/schemas/TonEncodedConfigDto'
        psbt:
          type: string
          description: Unsigned psbt bitcoin transaction
        signInputs:
          description: Indexes of inputs which user have to sign
          type: array
          items:
            type: number
        feeLimit:
          type: number
          description: Fee limit for tron blockchain
        callValue:
          type: string
          description: Native token value for tron blockchain
        signature:
          type: string
          description: Function signature of tron transaction
        arguments:
          description: ''
          type: array
          items:
            type: string
        rawParameter:
          type: string
          description: Encoded tron transaction arguments
        transaction:
          type: string
          description: Fee limit for tron blockchain
    TonEncodedConfigDto:
      type: object
      properties:
        address:
          type: string
          description: >-
            In default transfer - it's a receiverWalletAddress to send funds. In
            tx using contracts - it's a jettonWalletAddress (like ERC-20, but in
            TON)
        amount:
          type: string
          description: >-
            Amount to send tx in nanotons. In default trasfer - it's a
            transfered value + gasFee. 

            In tx using contracts - it's static gasFee, by default
            toNano(0.05).toString()
        payload:
          type: string
          description: Data for contract.
        stateInit:
          type: string
      required:
        - address
        - amount

````