Skip to main content
Glama
Abeautifulsnow

TDengine Query MCP Server

query_taos_db_data

Execute read-only SQL queries on TDengine databases to retrieve data, explore database structures, and investigate information directly from AI-powered tools.

Instructions

Important: Run a read-only SQL query on Taos database(涛思数据库).

    Args:
        sql_stmt (str): The sql statement you want to retrieve data from taos db.

    Returns:
        List: All data from the specified table.

    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sql_stmtYesThe sql statement you want to retrieve data from taos db

Implementation Reference

  • The implementation of the `query_taos_db_data` tool handler in the `tdengine_mcp_server`.
    @mcp.tool(name="query_taos_db_data")
    def query_taos_db_data(
        ctx: Context,
        sql_stmt: str = Field(
            description="The sql statement you want to retrieve data from taos db"
        ),
    ) -> TaosSqlResponse:
        """**Important**: Run a read-only SQL query on `Taos database(涛思数据库)`.
    
        Args:
            sql_stmt (str): The sql statement you want to retrieve data from taos db.
    
        Returns:
            List: All data from the specified table.
    
        """
    
        taos = ctx.request_context.lifespan_context.client
        return taos.execute_sql(sql_stmt)  # type: ignore

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/Abeautifulsnow/tdengine-mcp'

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