Skip to main content
Glama

GitHub MCP Server

by renantrendt
commits.ts726 B
import { z } from 'zod'; import { githubGet } from '../common/api.js'; // Schema for listing commits export const ListCommitsSchema = z.object({ owner: z.string(), repo: z.string(), sha: z.string().optional(), page: z.number().optional(), perPage: z.number().optional(), }); // List commits in a repository export async function listCommits( owner: string, repo: string, page?: number, perPage?: number, sha?: string ) { const endpoint = `/repos/${owner}/${repo}/commits`; const params: any = {}; if (sha) params.sha = sha; if (page) params.page = page; if (perPage) params.per_page = perPage; const response = await githubGet(endpoint, params); return await response.json(); }

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/renantrendt/mcp-github'

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