Skip to main content
POST
https://api.heyvincent.ai
/
user
/
{appId}
/
agent-funds
curl -X POST https://api.heyvincent.ai/user/123/agent-funds \
  -H "Content-Type: application/json" \
  -d '{
    "userControllerAddress": "0xUserWalletAddress...",
    "networks": ["base-mainnet", "base-sepolia"]
  }'
{
  "agentAddress": "0xAgentSmartAccountAddress...",
  "tokens": [
    {
      "address": "0xAgentSmartAccountAddress...",
      "network": "base-mainnet",
      "tokenAddress": "0xTokenContractAddress...",
      "tokenBalance": "1000000000000000000",
      "tokenMetadata": {
        "decimals": 18,
        "logo": "https://example.com/token-logo.png",
        "name": "USD Coin",
        "symbol": "USDC"
      },
      "tokenPrices": [
        {
          "currency": "usd",
          "value": "1.00",
          "lastUpdatedAt": "2024-01-01T00:00:00Z"
        }
      ]
    }
  ],
  "pageKey": "optional-pagination-key"
}
Retrieve the token balances held by the user’s agent smart account. This endpoint wraps the Alchemy Portfolio API to fetch token data across multiple networks.

Request

appId
integer
required
The unique identifier of the app
userControllerAddress
string
required
The Ethereum address of the user’s wallet
networks
string[]
required
Networks to query for token balances (e.g., ["base-mainnet", "base-sepolia"])

Response

agentAddress
string
The derived agent smart account address
tokens
array
List of tokens held by the agent
pageKey
string
Pagination key for fetching more results
curl -X POST https://api.heyvincent.ai/user/123/agent-funds \
  -H "Content-Type: application/json" \
  -d '{
    "userControllerAddress": "0xUserWalletAddress...",
    "networks": ["base-mainnet", "base-sepolia"]
  }'
{
  "agentAddress": "0xAgentSmartAccountAddress...",
  "tokens": [
    {
      "address": "0xAgentSmartAccountAddress...",
      "network": "base-mainnet",
      "tokenAddress": "0xTokenContractAddress...",
      "tokenBalance": "1000000000000000000",
      "tokenMetadata": {
        "decimals": 18,
        "logo": "https://example.com/token-logo.png",
        "name": "USD Coin",
        "symbol": "USDC"
      },
      "tokenPrices": [
        {
          "currency": "usd",
          "value": "1.00",
          "lastUpdatedAt": "2024-01-01T00:00:00Z"
        }
      ]
    }
  ],
  "pageKey": "optional-pagination-key"
}