Skip to main content
Glama
tigergraph

tigergraph-mcp

Official
by tigergraph

tigergraph__run_query

Run ad-hoc GSQL or openCypher queries on a TigerGraph graph without prior installation. Provide the query text to test or prototype, optionally specifying the target graph and connection profile.

Instructions

Run an interpreted query on a TigerGraph graph. Supports both GSQL and openCypher query languages. Use this for ad-hoc queries without needing to install them first.

Use When: • Running one-time or ad-hoc queries • Testing queries before installation • Simple data retrieval operations • Prototyping and exploration

Quick Start (GSQL):

{
  "query_text": "INTERPRET QUERY () FOR GRAPH MyGraph { SELECT v FROM Person:v LIMIT 5; PRINT v; }"
}

Quick Start (Cypher):

{
  "query_text": "INTERPRET OPENCYPHER QUERY () FOR GRAPH MyGraph { MATCH (n:Person) RETURN n LIMIT 5 }"
}

Common Workflow:

  1. Call 'show_graph_details' to understand the schema

  2. Write your query using vertex/edge types from schema

  3. Run with 'run_query' to test

  4. For repeated use, install with 'install_query'

Tips: • Query type auto-detected (GSQL vs Cypher) • For frequent queries, use 'install_query' + 'run_installed_query' for better performance • Always include 'FOR GRAPH' clause • Use LIMIT to avoid retrieving too much data

Warning: Syntax Notes: • GSQL: INTERPRET QUERY () FOR GRAPH <name> { <statements> } • Cypher: INTERPRET OPENCYPHER QUERY () FOR GRAPH <name> { <cypher> }

Related Tools: run_installed_query, install_query, get_neighbors

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
profileNoConnection profile name. Omit to use the active default profile. Use 'list_connections' to see available profiles.
graph_nameNoName of the graph. If not provided, uses default connection.
query_textYesQuery text to interpret and run. Supports both GSQL and openCypher queries. For GSQL: use 'INTERPRET QUERY () FOR GRAPH <graph> { <gsql_statements> }'. For openCypher: use 'INTERPRET OPENCYPHER QUERY () FOR GRAPH <graph> { <cypher_statements> }'. The query type is auto-detected based on the INTERPRET keyword used. Example (GSQL): `INTERPRET QUERY () FOR GRAPH MyGraph { SELECT v FROM Person:v }`Example (Cypher): `INTERPRET OPENCYPHER QUERY () FOR GRAPH MyGraph { MATCH (n) RETURN n LIMIT 5 }`

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.2

TDQS

A4.3/5.0
Behavior2/5

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

No annotations are provided, so the description must carry the full burden of disclosing behavioral traits. It does not explicitly state whether the query is read-only or may modify data, nor does it mention any side effects like authentication requirements or performance impacts. The term 'query' suggests reading, but it is not guaranteed in all cases, leaving room for misinterpretation.

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 organized into clear sections (Use When, Quick Start, Common Workflow, Tips, Warning, Related Tools), which makes it easy to scan. It is somewhat long, with some redundancy between the quick start examples and the syntax warning, but each section adds practical value without excessive repetition.

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

Completeness5/5

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

The description provides essential context for an agent: it explains the relationship with related tools (run_installed_query, install_query), references schema inspection via show_graph_details, and covers the full parameter set. It sufficiently describes when to use this tool versus others, making it complete for decision-making.

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

Parameters5/5

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

All three parameters (profile, graph_name, query_text) have descriptive schema entries. query_text is explained in detail with examples for both GSQL and Cypher, including auto-detection and syntax warnings. This fully covers parameter meaning and usage beyond just the schema field names.

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 that the tool runs an interpreted query on a TigerGraph graph, and explicitly distinguishes it from installed queries by noting it is for ad-hoc use. It also specifies that it supports both GSQL and openCypher, leaving no ambiguity about its primary function.

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?

The description provides explicit 'Use When' scenarios, quick-start examples for both query languages, a common workflow that references schema inspection and installation as a follow-up, and tips that mention when to use alternatives like install_query. This gives clear guidance on when and how to use the tool.

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/tigergraph/tigergraph-mcp'

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