Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.nexfi.robert.dpdns.org/llms.txt

Use this file to discover all available pages before exploring further.

Wallet Config and Assets

This page mirrors the detailed design style for the Wallet asset-side APIs, including endpoint purpose, request fields, response fields, and examples.

GET /api/v1/config/environment

Purpose

Returns runtime environment metadata, supported chains, and feature flags. The mobile client should call this during bootstrap.

Request Parameters

None.

Response Fields

FieldTypeDescriptionExample
codeIntegerBusiness status code. 0 means success.0
msgStringHuman-readable message.ok
data.environmentStringRuntime environment.prod
data.testnetOnlyBooleanWhether only testnets are exposed.true
data.supportedChainIdsInteger[]Chain IDs available to the client.[8453, 11155111]
data.buildVersionStringBackend config/build version.1.0.0
data.featureFlagsObjectFeature flag map.{ "balancesEnabled": true }
data.announcementObjectGlobal announcement payload.{ "enabled": false }
data.maintenanceObjectMaintenance mode payload.{ "enabled": false }

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "environment": "prod",
    "testnetOnly": true,
    "supportedChainIds": [8453, 11155111],
    "buildVersion": "1.0.0",
    "featureFlags": {
      "balancesEnabled": true,
      "historyEnabled": true,
      "contractsEnabled": true,
      "adminWriteEnabled": false
    },
    "announcement": {
      "enabled": false,
      "level": "info",
      "title": "",
      "message": ""
    },
    "maintenance": {
      "enabled": false,
      "reason": ""
    }
  }
}

GET /api/v1/networks

Purpose

Returns enabled mainnets and testnets for network switching, asset filters, and receive network selection.

Response Fields

FieldTypeDescriptionExample
data.mainnetsArrayEnabled mainnet list.[]
data.testnetsArrayEnabled testnet list.[]
data.*[].chainIdIntegerChain ID.8453
data.*[].nameStringChain name.Base
data.*[].nativeSymbolStringNative gas token symbol.ETH
data.*[].rpcUrlStringDefault RPC endpoint.https://...
data.*[].explorerUrlStringExplorer base URL.https://basescan.org
data.*[].faucetUrlStringFaucet URL for test assets.https://...
data.*[].isTestnetBooleanWhether the network is a testnet.false
data.*[].enabledBooleanWhether the network is enabled.true

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "mainnets": [
      {
        "chainId": 8453,
        "name": "Base",
        "nativeSymbol": "ETH",
        "rpcUrl": "https://mainnet.base.org",
        "explorerUrl": "https://basescan.org",
        "faucetUrl": "",
        "isTestnet": false,
        "enabled": true
      }
    ],
    "testnets": [
      {
        "chainId": 11155111,
        "name": "Sepolia",
        "nativeSymbol": "ETH",
        "rpcUrl": "https://rpc.sepolia.org",
        "explorerUrl": "https://sepolia.etherscan.io",
        "faucetUrl": "https://faucet.quicknode.com/ethereum/sepolia",
        "isTestnet": true,
        "enabled": true
      }
    ]
  }
}

GET /api/v1/tokens

Purpose

Queries the token directory for asset search, send-token selection, and receive-token display.

Query Parameters

ParameterTypeRequiredDescriptionExample
chainIdStringNoSingle-chain filter.8453
chainIdsStringNoMulti-chain filter, comma separated.1,8453,42161
qStringNoKeyword search.USDC
keywordStringNoKeyword alias of q.eth
addressStringNoExact contract address lookup, usually combined with chainId.0x833589f...
verifiedOnlyBoolean StringNoReturn only verified assets.true

Example Request

GET /api/v1/tokens?chainId=8453&keyword=USDC&verifiedOnly=true

Response Fields

FieldTypeDescriptionExample
data.itemsArrayToken result list.[]
data.items[].chainIdIntegerChain ID.8453
data.items[].addressStringContract address.0x833589f...
data.items[].symbolStringToken symbol.USDC
data.items[].nameStringToken name.USD Coin
data.items[].decimalsIntegerToken decimals.6
data.items[].logoUrlStringToken logo URL.https://...
data.items[].isVerifiedBooleanWhether the token is verified.true

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "items": [
      {
        "chainId": 8453,
        "address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
        "symbol": "USDC",
        "name": "USD Coin",
        "decimals": 6,
        "logoUrl": "https://assets.example.com/usdc.png",
        "isVerified": true
      }
    ]
  }
}

GET /api/v1/balances/{address}

Purpose

Returns native and token balances for a wallet address across selected chains. This is the main wallet asset API.

Path / Query Parameters

ParameterTypeRequiredDescriptionExample
addressStringYesWallet address.0xabc...
chainIdsStringNoSelected chain IDs, comma separated.8453,1
includeTokensBoolean StringNoWhether to include token balances.true
includeNativeBoolean StringNoWhether to include native balances.true

Example Request

GET /api/v1/balances/0xabc...?chainIds=8453&includeTokens=true&includeNative=true

Response Fields

FieldTypeDescriptionExample
data.addressStringWallet address.0xabc...
data.updatedAtStringAggregation timestamp.2026-05-11T10:00:00.000Z
data.chainsArrayChain summaries actually queried.[]
data.chains[].chainIdIntegerChain ID.8453
data.chains[].nameStringChain name.Base
data.chains[].isTestnetBooleanWhether testnet.false
data.balancesArrayBalance rows.[]
data.balances[].chainIdIntegerChain ID for the balance.8453
data.balances[].tokenAddressStringnative or contract address.native
data.balances[].symbolStringAsset symbol.ETH
data.balances[].nameStringAsset name.ETH
data.balances[].decimalsIntegerAsset decimals.18
data.balances[].balanceStringRaw balance in smallest unit.1000000000000000000
data.balances[].formattedBalanceStringUser-facing formatted balance.1
data.balances[].isNativeBooleanWhether this is the native token.true

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "address": "0xabc...",
    "updatedAt": "2026-05-11T10:00:00.000Z",
    "chains": [
      {
        "chainId": 8453,
        "name": "Base",
        "isTestnet": false
      }
    ],
    "balances": [
      {
        "chainId": 8453,
        "tokenAddress": "native",
        "symbol": "ETH",
        "name": "ETH",
        "decimals": 18,
        "balance": "1000000000000000000",
        "formattedBalance": "1",
        "isNative": true
      }
    ]
  }
}

GET /api/v1/prices

Purpose

Returns market prices for wallet valuation, asset detail display, and 24h price change.

Query Parameters

ParameterTypeRequiredDescriptionExample
symbolsStringNoComma-separated symbol list.ETH,USDC
assetsStringNoAsset identity list, extensible to chain+address keys.8453:0x8335...
currencyEnumNoQuote currency. Supports USD and CNY.USD

Example Request

GET /api/v1/prices?symbols=ETH,USDC&currency=USD

Response Fields

FieldTypeDescriptionExample
data.currencyStringQuote currency.USD
data.updatedAtStringPrice timestamp.2026-05-11T10:00:00.000Z
data.itemsArrayPrice rows.[]
data.items[].symbolStringAsset symbol.ETH
data.items[].usdPriceNumber | NullCurrent price.3500.12
data.items[].usdChange24hNumber | Null24h price change percent.-1.24

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "currency": "USD",
    "updatedAt": "2026-05-11T10:00:00.000Z",
    "items": [
      {
        "symbol": "ETH",
        "usdPrice": 3500.12,
        "usdChange24h": -1.24
      },
      {
        "symbol": "USDC",
        "usdPrice": 1,
        "usdChange24h": 0
      }
    ]
  }
}

GET /api/v1/receive/options/{address}

Purpose

Returns assets and networks that can be shown in the receive flow and QR-code share screen.

Path / Query Parameters

ParameterTypeRequiredDescriptionExample
addressStringYesWallet address.0xabc...
chainIdsStringNoChain filter.8453,1
includeZeroBoolean StringNoWhether to include zero-balance assets.false

Response Fields

FieldTypeDescriptionExample
data.addressStringWallet address.0xabc...
data.updatedAtStringAggregation timestamp.2026-05-11T10:00:00.000Z
data.assetsArrayReceivable assets.[]
data.assets[].symbolStringAsset symbol.USDC
data.assets[].nameStringAsset name.USD Coin
data.assets[].tokenAddressStringToken contract address.0x8335...
data.assets[].networksArraySupported receive networks.[]
data.assets[].networks[].chainIdIntegerNetwork chain ID.8453
data.assets[].networks[].nameStringNetwork name.Base
data.assets[].networks[].nativeSymbolStringNative gas symbol.ETH
data.assets[].networks[].explorerUrlStringExplorer base URL.https://basescan.org
data.assets[].networks[].faucetUrlStringFaucet URL when relevant.

Example Response

{
  "code": 0,
  "msg": "ok",
  "data": {
    "address": "0xabc...",
    "updatedAt": "2026-05-11T10:00:00.000Z",
    "assets": [
      {
        "symbol": "USDC",
        "name": "USD Coin",
        "tokenAddress": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
        "networks": [
          {
            "chainId": 8453,
            "name": "Base",
            "nativeSymbol": "ETH",
            "explorerUrl": "https://basescan.org",
            "faucetUrl": ""
          }
        ]
      }
    ]
  }
}