Skip to main content
Glama
mattcoatsworth

ShipStation API MCP Server

get_warehouse

Retrieve detailed warehouse information from the ShipStation API using the specified warehouse ID. Facilitates efficient management of warehouse-related data for streamlined operations.

Input Schema

NameRequiredDescriptionDefault
warehouseIdYesWarehouse ID to retrieve

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "warehouseId": { "description": "Warehouse ID to retrieve", "type": "number" } }, "required": [ "warehouseId" ], "type": "object" }

Implementation Reference

  • The handler function that executes the tool logic: fetches the warehouse using shipStationClient.getWarehouse and returns formatted MCP content or error response.
    handler: async ({ warehouseId }) => { try { const warehouse = await shipStationClient.getWarehouse(warehouseId); return { content: [{ type: "text", text: JSON.stringify(warehouse, null, 2) }] }; } catch (error) { return { content: [{ type: "text", text: error.message }], isError: true }; } }
  • Input schema using Zod to validate the warehouseId parameter.
    schema: { warehouseId: z.number().describe("Warehouse ID to retrieve") },
  • src/server.js:184-191 (registration)
    Registration of the get_warehouse tool (spread from warehouseTools array at line 178) with the MCP server via server.tool call in this loop.
    ].forEach(tool => { server.tool( tool.name, tool.schema, tool.handler, { description: tool.description } ); });
  • Supporting API client method that performs the actual HTTP request to the ShipStation /warehouses/{warehouseId} endpoint.
    async getWarehouse(warehouseId) { return this.request('GET', `/warehouses/${warehouseId}`); }

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

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