Skip to main content
Glama
get-list-of-projects.ts888 B
import { RequestHandlerExtra } from "@modelcontextprotocol/sdk/shared/protocol.js"; import { CallToolResult } from "@modelcontextprotocol/sdk/types.js"; import { JiraClient } from "../../services/jira-client.js"; export const getListOfProjects = async ( args: {}, extra: RequestHandlerExtra ): Promise<CallToolResult> => { try { const jiraClient = new JiraClient(); const projects = await jiraClient.getProjects(); return { content: [ { type: "text", text: `This are the projects available in JIRA. Data is in stringify format: ${JSON.stringify( projects )}`, }, ], }; } catch (error) { return { content: [ { type: "text", text: `Error: ${ error instanceof Error ? error.message : String(error) }`, }, ], }; } };

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

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