Skip to main content
Glama

get_label_by_name

Retrieve a specific label by name from a repository on the AtomGit platform. Specify the owner, repository, and label name to fetch the desired label information.

Instructions

Get a single label by name from a repository

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesLabel name
ownerYesRepository owner, typically referred to as 'username'. Case-insensitive.
repoYesRepository name. Case-insensitive.

Implementation Reference

  • Core handler function that performs the HTTP GET request to retrieve a specific label by name from the AtomGit API.
    export async function getLabelByName( owner: string, repo: string, name: string ) { return atomGitRequest( `https://api.atomgit.com/repos/${encodeURIComponent(owner)}/${encodeURIComponent(repo)}/labels/${encodeURIComponent(name)}`, { method: "GET", } ); }
  • Zod schema defining the input parameters for the get_label_by_name tool: owner, repo, and name.
    export const GetLabelByNameSchema = z.object({ owner: z.string().describe("Repository owner, typically referred to as 'username'. Case-insensitive."), repo: z.string().describe("Repository name. Case-insensitive."), name: z.string().describe("Label name"), });
  • index.ts:198-201 (registration)
    Tool registration in the list of available tools returned by ListToolsRequestHandler.
    name: "get_label_by_name", description: "Get a single label by name from a repository", inputSchema: zodToJsonSchema(label.GetLabelByNameSchema), },
  • MCP CallTool handler that parses arguments, calls the label.getLabelByName function, and formats the response.
    case "get_label_by_name": { const args = label.GetLabelByNameSchema.parse(request.params.arguments); const { owner, repo, name } = args; const result = await label.getLabelByName(owner, repo, name); return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }], }; }

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/kaiyuanxiaobing/atomgit-mcp-server'

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