Skip to main content
Glama

Xero MCP Server

Journals.ts764 B
import { XeroClientSession } from "../../XeroApiClient.js"; import { IMcpServerTool } from "../IMcpServerTool.js"; import { z } from "zod"; export const ListJournalsTool: IMcpServerTool = { requestSchema: { name: "list_journals", description: "Retrieves journals", inputSchema: { type: "object", properties: {} }, output: { content: [{ type: "text", text: z.string() }] }, }, requestHandler: async () => { const response = await XeroClientSession.xeroClient.accountingApi.getJournals( XeroClientSession.activeTenantId()!! ); const journals = response.body.journals || []; return { content: [ { type: "text", text: JSON.stringify(journals), }, ], }; }, };

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/john-zhang-dev/xero-mcp'

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