Functions
This document describes the /agent
endpoint, its functionality, and its use cases. Below is a detailed description of what this endpoint can do.
The /agent
endpoint can perform a wide range of Solana-related operations, including but not limited to:
1. Fetching Asset Information
Retrieves information about specific assets using their unique identifiers.
Example Query: "Get details of asset with ID
xyz123
."
2. Fetching Assets by Wallet Address
Retrieves all assets owned by a specific wallet address.
Example Query: "List all assets owned by wallet
ABCDEF123
."
3. Portfolio Management
Fetches the total portfolio value for a wallet, optionally with detailed breakdowns.
Example Query: "What is the detailed portfolio value for wallet
ABCDEF123
?"
4. Token Price Queries
Fetches the current price of tokens using their mint addresses.
Example Query: "Get the price of token with mint address
TOKEN123
."
5. NFT Operations
Lists NFTs for sale on platforms like TensorSwap.
Cancels NFT listings.
Example Query: "List this NFT for sale at 5 SOL."
6. Token Swaps
Executes swaps between different tokens.
Example Query: "Swap 10 SOL for USDC."
7. Fungible Token Queries
Retrieves all fungible tokens owned by a specific wallet.
Example Query: "List fungible tokens for wallet
ABCDEF123
."
8. Handling SPL Token Portfolios
Provides detailed insights into SPL token holdings, including balances and historical data.
Example Query: "Show SPL token portfolio for wallet
ABCDEF123
."
9. Network-Specific Queries
Supports operations on both
mainnet
anddevnet
environments.Example Query: "Get portfolio value on
devnet
."
Response Format
Successful Response
Error Response
Development Details
Programming Language: Python
Libraries and Frameworks: The
/agent
endpoint utilizes various Python libraries to interact with the Solana blockchain, perform computations, and respond to user queries effectively.Integrations:
Solana APIs
TensorSwap for NFT operations
SPL Token interfaces for fungible token management
Last updated