Skip to main content
Glama

boj_github_get_file

Retrieve file contents from GitHub repositories by specifying owner, repository, and file path. This tool enables access to code, documentation, or configuration files stored in GitHub for integration or analysis purposes.

Instructions

Get file contents from a repo

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ownerYes
repoYes
pathYes
refNo

Implementation Reference

  • The handler logic for "boj_github_get_file" within the handleGitHubTool function, which calls the GitHub API directly.
    case "boj_github_get_file":
      return githubApiCall("GET", `/repos/${args.owner}/${args.repo}/contents/${args.path}?ref=${args.ref || "main"}`);
  • The schema definition (name, description, input properties, and requirements) for the "boj_github_get_file" tool.
    { name: "boj_github_get_file", desc: "Get file contents from a repo", props: { owner: { type: "string" }, repo: { type: "string" }, path: { type: "string" }, ref: { type: "string" } }, req: ["owner", "repo", "path"] },

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/hyperpolymath/boj-server'

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