Skip to main content
Glama

read_repo_file

Read file contents from Git repositories to view source code, configuration, or documentation. Use this tool to access specific files by providing repository name and file path.

Instructions

Read the content of a single file from a Git repository.

USE THIS TOOL when the user wants to see source code, config, or content of a specific file. Get the path from browse_repo first.

Args: repo_name: Repository name. path: Full file path (e.g. '/src/main.py'). Use forward slashes. branch: Branch name (default: repo's default branch). project: Project name (default from config).

Returns the raw file content with metadata header.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
repo_nameYes
pathYes
branchNo
projectNo

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/SrujanReddyKallu2024/MCP'

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