Skip to main content
Glama

get_orders_report

Generate and retrieve order reports from ShipBob's fulfillment platform by specifying date ranges and sales channels for analysis.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
startDateYesStart date for the report (YYYY-MM-DD)
endDateYesEnd date for the report (YYYY-MM-DD)
channelIdNoFilter by sales channel ID

Implementation Reference

  • The main handler function for the 'get_orders_report' tool. It constructs parameters and calls the ShipBob API via shipbobClient, then returns a formatted text response or error.
    handler: async ({ startDate, endDate, channelId }) => { try { const params = { startDate, endDate, channelId }; const report = await shipbobClient.getOrdersReport(params); return { content: [{ type: "text", text: JSON.stringify(report, null, 2) }] }; } catch (error) { return { content: [{ type: "text", text: `Error retrieving orders report: ${error.message}` }], isError: true }; } }
  • Zod schema defining the input parameters for the tool: required startDate and endDate (YYYY-MM-DD format), optional channelId.
    schema: { startDate: z.string().describe("Start date for the report (YYYY-MM-DD)"), endDate: z.string().describe("End date for the report (YYYY-MM-DD)"), channelId: z.string().optional().describe("Filter by sales channel ID") },
  • src/server.js:58-58 (registration)
    Registers the reportingTools array (containing get_orders_report) with the MCP server using the registerTools utility function.
    registerTools(reportingTools);
  • Helper method in ShipBobClient that performs the actual API request to retrieve the orders report from ShipBob's /reports/orders endpoint.
    async getOrdersReport(params) { return this.request('GET', '/reports/orders', null, params); }

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

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