Skip to main content
Glama

Skill-to-MCP

get_skill_related_file

Retrieve file content or paths from skill directories to access supporting scripts, documentation, and resources for AI skill implementation.

Instructions

Read the content of a specific file within a skill directory.

This tool returns the requested file based on a path relative to the skill's SKILL.md location. Use get_skill_details() first to see the list of available files.

Parameters

skill_name : str The name of the skill. relative_path : str Path to the file relative to the skill directory (e.g., "scripts/qc_core.py"). return_type : str Type of data to return: "content" (default), "file_path", or "both". - "content": Returns only the file content as text - "file_path": Returns only the absolute path to the file - "both": Returns both content and file path in a dict

Returns

str | dict[str, str] If return_type is "content": The content of the requested file. If return_type is "file_path": The absolute path to the file. If return_type is "both": Dictionary with "content" and "file_path" keys.

Raises

ValueError If the skill or file is not found, if the path is invalid, or if return_type is invalid.

Examples

content = get_skill_related_file("single-cell-rna-qc", "scripts/qc_core.py", return_type="content") print(len(content) > 0) True

Input Schema

NameRequiredDescriptionDefault
skill_nameYes
relative_pathYes
return_typeNoboth

Input Schema (JSON Schema)

{ "properties": { "relative_path": { "type": "string" }, "return_type": { "default": "both", "type": "string" }, "skill_name": { "type": "string" } }, "required": [ "skill_name", "relative_path" ], "type": "object" }

Other Tools from Skill-to-MCP

Related Tools

    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/biocontext-ai/skill-to-mcp'

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