Skip to main content
Glama
baskcart

W3Ship MCP Server

by baskcart

get_order

Retrieve detailed order information by ID to track shipments and manage fulfillment processes.

Instructions

Retrieve detailed information about a specific Order (TMF622).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe generic Order ID

Implementation Reference

  • Tool handler for 'get_order' in the main server loop, which imports and calls the orderService.getOrder method.
    case 'get_order': {
        const { orderService } = await import('./orders/service.js');
        const id = args?.id as string;
        const order = await orderService.getOrder(id);
        if (!order) {
            return { content: [{ type: 'text', text: `Error: Order not found: ${id}` }], isError: true };
        }
        return { content: [{ type: 'text', text: JSON.stringify(order, null, 2) }] };
    }
  • The actual implementation of the getOrder logic that fetches the order data from the Redis/Valkey store.
    async getOrder(orderId: string): Promise<Order | null> {
        const data = await this.getClient().get(`order:${orderId}`);
        if (!data) return null;
        return JSON.parse(data);
    }

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

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