Skip to main content
Glama
ariesanhthu

VNStock MCP Server

by ariesanhthu

get_company_overview

Retrieve company overview data from Vietnam's stock market by providing a stock symbol, with output available in JSON or dataframe format.

Instructions

Get company overview from stock market
Args:
    symbol: str
    output_format: Literal['json', 'dataframe'] = 'json'
Returns:
    pd.DataFrame

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
symbolYes
output_formatNojson

Implementation Reference

  • The main handler function for the 'get_company_overview' MCP tool. It is decorated with @server.tool() for registration. Fetches company overview data using TCBSCompany from vnstock and returns it as JSON or pandas DataFrame based on the output_format parameter.
    @server.tool()
    def get_company_overview(
        symbol: str, output_format: Literal["json", "dataframe"] = "json"
    ):
        """
        Get company overview from stock market
        Args:
            symbol: str
            output_format: Literal['json', 'dataframe'] = 'json'
        Returns:
            pd.DataFrame
        """
        equity = TCBSCompany(symbol=symbol)
        df = equity.overview()
        if output_format == "json":
            return df.to_json(orient="records", force_ascii=False)
        else:
            return df
  • The @server.tool() decorator registers the get_company_overview function as an MCP tool with the FastMCP server.
    @server.tool()
  • Input schema defined by function parameters with type hints (symbol: str, output_format: Literal["json", "dataframe"] = "json") and docstring describing args and return type.
    def get_company_overview(
        symbol: str, output_format: Literal["json", "dataframe"] = "json"
    ):
        """
        Get company overview from stock market
        Args:
            symbol: str
            output_format: Literal['json', 'dataframe'] = 'json'
        Returns:
            pd.DataFrame
        """
Behavior2/5

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

No annotations are provided, so the description carries full burden for behavioral disclosure. It mentions the return type (pd.DataFrame) but doesn't describe what data the overview contains, whether it's real-time or historical, any rate limits, authentication requirements, or error conditions. For a stock market data tool with zero annotation coverage, this leaves significant behavioral gaps.

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

Conciseness4/5

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

The description is efficiently structured with clear sections for Args and Returns. Each sentence serves a purpose: stating the tool's function, documenting parameters, and specifying return type. While it could be slightly more concise by combining lines, there's minimal wasted verbiage and good front-loading of the core purpose.

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

Completeness2/5

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

For a stock market data tool with 2 parameters, no annotations, and no output schema, the description is incomplete. It doesn't explain what 'company overview' actually includes (financial metrics? business description? stock performance?), doesn't mention data sources or freshness, and provides minimal behavioral context. The return type mention helps but doesn't substitute for proper output documentation.

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

Parameters3/5

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

Schema description coverage is 0%, so the description must compensate. It documents both parameters (symbol and output_format) with their types and default values, which adds meaningful semantics beyond the bare schema. However, it doesn't explain what constitutes a valid symbol format (e.g., ticker conventions) or clarify the practical difference between json and dataframe output formats beyond type names.

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

Purpose4/5

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

The description clearly states the action ('Get company overview') and resource ('from stock market'), making the purpose understandable. It distinguishes this tool from siblings like get_balance_sheets or get_income_statements by focusing on a general overview rather than specific financial statements. However, it doesn't explicitly differentiate from tools like get_company_ratio_summary or get_company_trading_stats that might provide overlapping summary data.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. With many sibling tools available (e.g., get_company_ratio_summary, get_company_trading_stats), there's no indication of what makes this 'overview' distinct or when it should be preferred over other company data tools. The agent must infer usage from the name alone.

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/ariesanhthu/mcp-server-vietnam-stock-trading'

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