Skip to main content
Glama
gscfwid

NCCN Guidelines MCP Server

by gscfwid

get_index

Retrieve the raw YAML content of the NCCN guidelines index for accurate access to clinical cancer treatment information.

Instructions

Get the raw contents of the NCCN guidelines index YAML file. Returns: String containing the raw YAML content of the guidelines index

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the MCP tool 'get_index'. It reads and returns the raw YAML content of the NCCN guidelines index file created by the initialization process.
    @mcp.tool() async def get_index() -> str: """ Get the raw contents of the NCCN guidelines index YAML file. Returns: String containing the raw YAML content of the guidelines index """ try: index_path = current_dir / GUIDELINES_INDEX_FILE with open(index_path, 'r', encoding='utf-8') as f: content = f.read() logger.info(f"Successfully loaded guidelines index from {index_path}") return content except FileNotFoundError: logger.error(f"Guidelines index file not found: {index_path}") return "Error: Guidelines index file not found" except Exception as e: logger.error(f"Error reading guidelines index: {str(e)}") return f"Error reading guidelines index: {str(e)}"
  • server.py:146-146 (registration)
    The @mcp.tool() decorator registers the get_index function as an MCP tool.
    @mcp.tool()
  • During server initialization, ensure_nccn_index is called to create/update the guidelines index file that get_index reads.
    guidelines_data = await ensure_nccn_index( output_file=str(current_dir / GUIDELINES_INDEX_FILE), max_age_days=7 # Refresh index every 7 days )

Other Tools

Related 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/gscfwid/NCCN_guidelines_MCP'

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