Skip to main content
Glama
peakacom

peaka-mcp-server

Official
by peakacom

peaka_execute_sql_query

Execute SQL queries on Peaka projects by providing a project ID and query statement. Requires prior schema inspection and caching check for optimal querying.

Instructions

Runs the given sql query on Peaka.

BEFORE RUNNING THIS TOOL:
  1: Use peaka_get_project_metadata to determine which tables should be used in the query and their schemas.
  2: Use peaka_list_tables to determine if the tables of interest are cached or not (this response has isCached property)
  3: If one or more tables that you need to query are cacheable but not cached:
    3a: Warn the user that the results will be limited and ask if you should start the caching process for those tables, and start the caching process using the create cache tool
    3b: If the caching is rejected by the user, warn them that the query results will be limited and use LIMIT statements on the query to make sure it doesn't run forever

If you do not already know the projectId for the current task, call peaka_list_projects first and ask the user which project to use. Remember the chosen projectId for subsequent calls in this conversation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
projectIdYesThe Peaka project ID to run against.
Behavior3/5

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

Describes limited results when tables are not cached, but lacks details on whether the tool supports DML (INSERT/UPDATE/DELETE) or only SELECT. No mention of rate limits, timeout, or output format. Annotations provide no additional safety hints.

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?

Front-loaded with purpose and well-structured preconditions. Slightly verbose but each part earns its place, guiding the agent effectively.

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?

Missing details on return format, error handling, and whether the tool can modify data. The caching guidance helps, but overall incomplete for a query execution tool with no output schema.

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

Parameters2/5

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

Schema coverage is 50% (projectId has description, query does not). The description adds no parameter-specific meaning beyond the schema, focusing only on pre-conditions.

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 tool runs SQL queries on Peaka. It distinguishes from siblings like peaka_list_tables and peaka_get_project_metadata by focusing on execution, but does not differentiate from the similar peaka_execute_query sibling.

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

Usage Guidelines5/5

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

Provides explicit step-by-step preconditions: check metadata, check caching, warn user, and handle caching. Clear when to use and what to do before invoking.

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/peakacom/peaka-mcp-server'

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