Skip to main content
Glama
saikrmet

nasa-exoplanet-mcp

by saikrmet

run_query

Read-onlyIdempotent

Run raw ADQL queries against NASA's Exoplanet Archive for complex astronomy searches—aggregation, joins, and spatial cone searches beyond basic planet filters.

Instructions

Execute a raw ADQL query against the NASA Exoplanet Archive TAP service. ADQL is an SQL-like language for astronomical databases. Use this for complex queries that search_planets cannot handle: GROUP BY aggregations, COUNT statistics, JOINs across tables, spatial/cone searches, queries against non-planet tables (toi, transitspec, emissionspec, ml, Kepler KOI tables), or any query needing full SQL-like flexibility.

Use list_tables and list_columns first to discover available tables and column names. Common tables: pscomppars (one row per confirmed planet), ps (all published solutions — filter with default_flag=1 for one per planet), stellarhosts (host stars), toi (TESS candidates), transitspec (atmospheric transit spectra), emissionspec (atmospheric emission spectra), ml (microlensing planets).

ADQL supports: SELECT, WHERE, ORDER BY, GROUP BY, COUNT, JOIN, LIKE, BETWEEN, IS NULL, IS NOT NULL, TOP, mathematical functions, and spatial functions (CONTAINS, POINT, CIRCLE for cone searches). Example cone search: WHERE CONTAINS(POINT('ICRS',ra,dec), CIRCLE('ICRS',291.0,48.0,5.0))=1

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum rows to return (1-1000, default 100). Applied as maxrec parameter. You can also use TOP N in your ADQL SELECT clause.
queryYesADQL query string. Example: SELECT pl_name, pl_rade, pl_bmasse FROM pscomppars WHERE pl_rade < 2 AND pl_bmasse IS NOT NULL ORDER BY pl_rade

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations already mark the tool as read-only, open-world, idempotent, and non-destructive. The description adds substantial behavioral context: it's a raw ADQL executor with SQL-like flexibility, lists supported functions, provides a cone-search example, and clarifies table semantics. It does not contradict annotations, though it stops short of detailing rate limits or error behavior.

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 appropriately detailed for a complex query tool. It is front-loaded with the core purpose, then systematically covers when to use, prerequisites, table inventory, supported syntax, and an example—every sentence adds value without fluff.

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?

For a tool with two parameters, an output schema, and rich annotations, the description is outstandingly complete. It covers the query language, common table names, example queries, and explicitly differentiates from sibling tools. The agent has everything needed to invoke it correctly and interpret results.

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?

Schema coverage is 100%, so baseline is 3. The description goes beyond schema by explaining the ADQL dialect, giving a cone-search example, and describing common tables and their meanings—all of which help the agent construct a correct 'query' string. The 'limit' parameter is effectively explained via 'maxrec' and 'TOP N' mention.

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 opens with a specific verb and resource: 'Execute a raw ADQL query against the NASA Exoplanet Archive TAP service.' It clearly distinguishes the tool from search_planets by listing advanced use cases like GROUP BY, JOINs, and spatial/cone searches that the simpler tool cannot handle.

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?

Explicit guidance is provided on when to use this tool versus alternatives: 'Use this for complex queries that search_planets cannot handle' with concrete examples. It also advises a discovery workflow ('Use list_tables and list_columns first') and names common tables, giving clear context for selection.

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/saikrmet/nasa-exoplanet-mcp'

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