Skip to main content
Glama

get_all_wallets

Retrieve a complete list of cryptocurrency wallets with their current balances and assets for portfolio management and tracking across supported blockchain networks.

Instructions

Retrieve all wallets with balances.

Returns a list of Wallets and asssets

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
get_all_wallets_requestsYes

Implementation Reference

  • MCP tool handler decorated with @mcp.tool(). Proxies the request to the ArmorWalletAPIClient's get_all_wallets method, handling authentication check and errors.
    @mcp.tool()
    async def get_all_wallets(get_all_wallets_requests: ListWalletsRequest) -> List[Wallet]:
        """
        Retrieve all wallets with balances.
        
        Returns a list of Wallets and asssets
        """
        if not armor_client:
            return [{"error": "Not logged in"}]
        try:
            result: List[Wallet] = await armor_client.get_all_wallets(get_all_wallets_requests)
            return result
        except Exception as e:
            return [{"error": str(e)}]
  • Pydantic models defining the input schema (ListWalletsRequest) and output schema (Wallet, extending WalletInfo with balances as List[WalletBalance]). Used for validation and typing.
    class ListWalletsRequest(BaseModel):
        is_archived: bool = Field(default=False, description="whether to include archived wallets")
    
    
    class WalletBalance(BaseModel):
        mint_address: str = Field(description="public mint address of output token. To get the address from a token symbol use `get_token_details`")
        name: str = Field(description="name of the token")
        symbol: str = Field(description="symbol of the token")
        decimals: int = Field(description="number of decimals of the token")
        amount: float = Field(description="balance of the token")
        usd_price: str = Field(description="price of the token in USD")
        usd_amount: float = Field(description="balance of the token in USD")
    
    
    class WalletInfo(BaseModel):
        id: str = Field(description="wallet id")
        name: str = Field(description="wallet name")
        is_archived: bool = Field(description="whether the wallet is archived")
        public_address: str = Field(description="public address of the wallet")
    
    
    class Wallet(WalletInfo):
        balances: List[WalletBalance] = Field(description="list of balances of the wallet")
  • Implementation of get_all_wallets in ArmorWalletAPIClient class. Performs the actual HTTP GET request to the Armor API endpoint `/wallets/?is_archived={data.is_archived}` using the shared _api_call method.
    async def get_all_wallets(self, data: ListWalletsRequest) -> List[Wallet]:
        """Return all wallets with balances."""
        return await self._api_call("GET", f"wallets/?is_archived={data.is_archived}")

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/emmaThompson07/armor-crypto-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server