Skip to main content
Glama

list_currencies

Retrieve currency codes, names, and regions from the Swiss National Bank for CHF exchange rate data. Access Swiss open data without API keys.

Instructions

List all currencies available from the Swiss National Bank (SNB) for CHF exchange rate data. Returns currency codes, names, and regions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The 'handleListCurrencies' function fetches currency dimensions from the SNB API and returns a formatted JSON string with currency details.
    async function handleListCurrencies(): Promise<string> {
      const currencies = await fetchDimensions();
    
      const result = currencies.map((c) => ({
        code: c.code,
        name: c.name,
        region: c.region || undefined,
        units: c.units === 100 ? `CHF per 100 ${c.code}` : `CHF per 1 ${c.code}`,
        seriesId: c.seriesId,
      }));
    
      return JSON.stringify(
        {
          currencies: result,
          count: result.length,
          note: "All rates are CHF per unit. Series with '100' suffix (e.g. JPY100) show CHF per 100 units.",
          source: "https://data.snb.ch",
        },
        null,
        2
      );
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It mentions the return format ('currency codes, names, and regions'), which is helpful, but it doesn't disclose behavioral traits such as data freshness, rate limits, authentication needs, or error handling. This is a significant gap for a tool with no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the purpose and includes essential details like the source and return format. There's no wasted verbiage, making it highly concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity (0 parameters, no output schema, no annotations), the description is adequate but incomplete. It covers the purpose and return format, but without annotations or output schema, it should ideally include more behavioral context (e.g., data source reliability, update frequency) to be fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has 0 parameters with 100% schema description coverage, so no parameter information is needed. The description doesn't add parameter semantics, but that's acceptable here. A baseline of 4 is appropriate as it doesn't detract from the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List all currencies'), specifies the resource ('available from the Swiss National Bank (SNB) for CHF exchange rate data'), and distinguishes it from siblings like 'get_exchange_rate' or 'get_exchange_rate_history' by focusing on metadata rather than rates. It's specific and avoids tautology.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for obtaining currency metadata before fetching exchange rates, but it doesn't explicitly state when to use this tool versus alternatives like 'get_exchange_rate' or provide exclusions. The context is clear but lacks explicit guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/vikramgorla/mcp-swiss'

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