skyportal-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| SKYPORTAL_URL | Yes | Your SkyPortal/Fritz instance URL | |
| SKYPORTAL_TOKEN | Yes | Your API token from your profile page |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
| logging | {} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| extensions | {
"io.modelcontextprotocol/ui": {}
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| get_source_photometryA | Retrieve photometry for a source as a CSV table. Returns all photometry points for the source in CSV format, suitable for direct analysis or loading into a pandas DataFrame. Columns returned (mag format): mjd, filter, mag, magerr, limiting_mag, snr, instrument_name, origin Columns returned (flux format): mjd, filter, flux, fluxerr, snr, instrument_name, origin |
| get_source_spectraA | Retrieve spectra for a source. By default returns a summary to avoid token overflow. Use verbose=True or format="csv" to get full spectral data. |
| get_source_classificationsA | Retrieve classifications for a source. Returns all classifications assigned to the source, including the classification name, probability, and who made the classification. |
| get_source_comments_and_annotationsA | Retrieve comments and annotations for a source. Returns a summary of user comments and system/ML annotations on the source. Comments are human-readable notes; annotations are structured data (e.g., ML scores, cross-match results). |
| get_source_host_galaxyA | Retrieve host galaxy information for a source. Returns the associated host galaxy from SkyPortal's galaxy catalogs, including angular separation (offset) and physical distance. SkyPortal can link sources to host galaxies from catalogs like GLADE+. If a host association exists, this returns the galaxy's properties. |
| get_tns_summaryA | SUMMARY TOOL: Generate complete TNS/AstroNote report for a transient. USE THIS SINGLE TOOL when asked to create TNS reports, AstroNotes, or comprehensive source summaries. It combines all relevant data in one call. This tool retrieves and formats ALL information needed for TNS submissions:
Accepts ANY source identifier: SkyPortal obj_id, ZTF name, or TNS name. When to use:
Do NOT call multiple other tools (photometry, spectra, classifications) separately when this single tool provides everything together. |
| analyze_light_curveA | Analyze light curve evolution for multiple photometric bands. Calculates key temporal properties of a transient's light curve including rise time, fade time, total duration, and pre-peak variability (flares) for each requested photometric band. Handles incomplete light curves:
Generates CSV data file + Jupyter notebook with interactive Plotly plots showing all bands overlaid, plus editable analysis code cells. |
| analyze_color_evolutionA | Analyze color evolution and color at peak brightness. Calculates color curves (band1 - band2) using BOTH methods:
Generates CSV data file + Jupyter notebook with overlaid plots. |
| get_api_quick_referenceA | Get the SkyPortal API quick reference guide. Returns a reference of available API endpoints, required parameters, and usage patterns. Call once to load into context as needed. |
| get_tools_quick_referenceA | Get the MCP tools quick reference guide. Returns a comprehensive list of all available MCP tools organized by category, with common workflows and usage examples. Call once to load into context when needed. |
| call_skyportal_apiA | Make an API call to SkyPortal. ⚠️ WRITE RISK: POST, PUT, and DELETE requests will permanently modify or delete data on your SkyPortal/Fritz instance. These operations cannot be undone through this tool. Always confirm the endpoint and payload before using a non-GET method. |
| convert_timeA | Convert between MJD, JD, ISO datetime, and Unix timestamps. |
| get_survey_urlsA | Get URLs to browse a sky position in common astronomical surveys. Provide either ra/dec coordinates or a source_id to auto-resolve coordinates from SkyPortal. |
| search_sources_near_positionA | Search for sources in SkyPortal near a position (cone search). Finds all sources within a specified radius of a sky position. Useful for checking if a source already exists in SkyPortal at a given location, or finding nearby sources. Provide either ra/dec coordinates or a source_id to auto-resolve coordinates. |
| generate_bulk_lightcurve_codeA | Generate a Jupyter notebook to bulk download ZTF light curves from Fritz. Creates a ready-to-run .ipynb notebook that uses ztfquery's Fritz integration to download alert photometry (detection epochs) for multiple sources with multiprocessing, save results to CSV, and create interactive Plotly plots. Note: This downloads alert photometry, not forced photometry. For forced photometry (including non-detections/upper limits), use the IRSA ZTF forced photometry service. Requires: ztfquery + Fritz API token.
Setup: |
| generate_cone_search_codeA | Generate code to perform ZTF cone searches at multiple positions. This tool generates Python code that searches for ZTF detections within a radius of specified sky coordinates. Useful for cross-matching catalogs or checking if known positions have ZTF coverage. Use Case: When you have a list of coordinates (e.g., from a catalog, TNS, or previous observations) and want to find all ZTF detections nearby. |
| generate_fritz_bulk_query_codeA | Generate code to bulk query Fritz/SkyPortal for multiple sources. This tool generates code that uses ztfquery's Fritz interface to download photometry, spectra, and metadata for multiple sources from Fritz. Use Case: When you need to download data products from Fritz for many sources at once (faster than individual API calls). Note: Requires Fritz API token.
Setup: |
| generate_alert_download_codeA | Generate code to download ZTF alert packets for multiple sources. This tool generates code that downloads raw ZTF alert packets, which contain the full alert history including candidate info, cutouts, and previous detections. Use Case: When you need complete alert history or want to access alert-level data that isn't available in forced photometry. |
| generate_field_visualization_codeA | Generate code to visualize ZTF field and CCD coverage. This tool generates code to create sky maps showing ZTF field footprints and CCD layouts. Useful for understanding coverage and planning observations. Use Case: When you need to visualize which parts of the sky are covered by specific ZTF fields or CCDs. |
| get_candidate_filter_referenceA | Get the reference for filtering candidates and sources on Fritz/SkyPortal. Returns documentation on available query parameters for the /api/candidates endpoint: annotation-based filters for ML scores (real/bogus, star/galaxy), classification filters, redshift, photometry annotations, and more. Call this when a user asks to filter, search, or scan for specific types of transients. It tells you what's filterable via API queries vs what requires fetching data and doing custom computation. Note: This is for query-time filtering (scanning page searches), NOT for creating alert-time MongoDB filters that run on Kowalski. |
| filter_candidatesA | Search for candidates matching specific criteria on the scanning page. This performs query-time filtering of existing candidates (not alert-time filtering). Use this to search the scanning page for candidates matching specific properties. IMPORTANT - Parameter Validation: Before executing this tool, ALWAYS confirm with the user that the filter parameters are reasonable. Explain what the filter will return and ask if they want to proceed. Examples:
IMPORTANT - After Results: After showing results, offer to display the filter configuration JSON so the user can save it for future use or configure it in the UI. |
| generate_watchlist_filterA | Generate MongoDB filter JSON for a watchlist to monitor specific coordinates. Watchlists are alert-time filters that flag new detections near specified sky positions. They run on the Kowalski backend as part of Fritz's alert stream processing. This tool generates the MongoDB aggregation pipeline JSON compatible with Fritz's filter system. IMPORTANT - This is an ALERT-TIME filter:
RECOMMENDED WORKFLOW (MongoDB Compass): Fritz now recommends using MongoDB Compass for filter development:
ALTERNATIVE - Direct Use: You can also use the generated JSON directly:
|
| get_source_observabilityA | Compute observing windows for a source from specified telescopes. USE THIS TOOL for all observability questions. Do NOT use the /api/sources/{id}/observability endpoint (that returns a PDF image which cannot be parsed). Provide either a source_id (auto-resolves RA/Dec from SkyPortal) or explicit ra/dec coordinates. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| get_api_docs | Quick reference guide for common SkyPortal API endpoints |
| get_tools_docs | Quick reference guide for all available MCP tools |
| get_filter_docs | Candidate and source filtering reference guide |
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/AnastasiaKWei/skyportal-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server