LogoLogo
WebsiteLoginStatus
API Reference
API Reference
  • Introduction
  • Introduction to GraphQL
    • What is GraphQL?
      • GraphQL Schema
      • Example Using GraphQL
    • Authentication
    • Queries
      • Example Query
    • Mutations
      • Example Mutation
    • Variables
    • Fields
  • Develop With inabit API
    • Getting Started
      • Authentication
      • inabit Postman Collection
    • Organizations
      • Organization Info
      • Organization ID
      • Organization Users
      • Organization Contacts
      • Organization Transactions
    • Wallets
      • Wallets Info
      • Create inabit Wallet
      • Edit Wallet Name
      • Generate Deposit Address
      • Fetch Deposit Address
      • Save Address to Whitelist
      • Archive / Unarchive Wallet
      • Disconnect Exchange Wallet
    • Contacts
      • Contact Info
      • Create New Contact
      • Update Contact
    • Transactions
      • Transaction Info
      • Create Transfer Request
      • Create Off Ramp Request
      • Create On Ramp Request
      • Create Exchange Swap
      • Create inabit Wallet Swap
      • Edit Transaction Note
    • Utilities
      • Fetch Financial Asset
      • Fetch Blockchains
  • Remote Approver App
    • Setup and Configuration
    • API Wallets Generation
    • Automate Signing Transactions
    • Webhooks
      • Notification Types
  • WHAT WE SUPPORT
    • Assets & Tokens
    • Blockchains
    • Exchanges
      • Binance
      • Kucoin
      • Kraken
  • Changelog
Powered by GitBook
On this page
  • Get an Existing Wallet Deposit Address
  • Headers
  • Body (WalletDepositAddressWhereInput object)
  • Response
  • Try it out!

Was this helpful?

Export as PDF
  1. Develop With inabit API
  2. Wallets

Fetch Deposit Address

Fetching an existing coin/asset blockchain address within a wallet

PreviousGenerate Deposit AddressNextSave Address to Whitelist

Was this helpful?

Get an Existing Wallet Deposit Address

The GetOrCreateDepositAddress query allows API users to fetch an existing blockchain address for an asset & blockchain in their wallet. If there isn't one, the query will return an error and you will need to use query beforehand to add a coin first.

Do note that currently, this query is called GetOrCreateDepositAddress while in fact this query cannot create/generate a new blockchain deposit address for a wallet. This confusion will be fixed and deprecated in future versions of the API.

query GetOrCreateDepositAddress($where: WalletDepositAddressWhereInput!) {
  getOrCreateDepositAddress(where: $where) {
    address
  }
}

Headers

Name
Value

Content-Type

application/json

Authorization

Bearer <token>

Body (WalletDepositAddressWhereInput object)

Name
Type
Description

walletId*

string

ID of the wallet

financialAssetId*

string

ID of the financial asset in inabit (can be token/native)

blockchainId*

string

ID of the blockchain in inabit

Example body:

{
  "where": {
    "walletId": "clmq35x0400009k01v5ptn7d5",
    "assetId": "clefn78h5012plc6rxbmofnop",
    "blockchainId": "clefn78cl00i3lc6rih442mx9"
  }
}

Response

Return values:

Name
Type
Description

address

String

API Wallet Address

{
  "data": {
    "getOrCreateDepositAddress": {
      "address": "0x429de487cF185eFBBEb3158D2FbC1C003462018c",
    }
  }
}
{
  "error": "Invalid request"
}

In the query's response, you will receive the created API wallet address for the wallet, asset & blockchain IDs given in the body.

Try it out!

Generate Deposit Address
Apollo Studio