Skip to main content
Glama

get_order

Retrieve specific order details from SAP Commerce Cloud using user ID and order code to track purchases and manage customer transactions.

Instructions

Get details of a specific order

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
userIdYesUser ID or email
orderCodeYesOrder code/number

Implementation Reference

  • The implementation of the getOrder tool, which performs an API request to fetch order details.
    async getOrder(userId: string, orderCode: string): Promise<Order> {
      return this.request<Order>(
        `/occ/v2/${encodeURIComponent(this.config.baseSiteId!)}/users/${encodeURIComponent(userId)}/orders/${encodeURIComponent(orderCode)}?fields=FULL`
      );
    }
  • src/index.ts:177-193 (registration)
    Tool definition and registration for 'get_order' in the MCP server index.
      name: 'get_order',
      description: 'Get details of a specific order',
      inputSchema: {
        type: 'object',
        properties: {
          userId: {
            type: 'string',
            description: 'User ID or email',
          },
          orderCode: {
            type: 'string',
            description: 'Order code/number',
          },
        },
        required: ['userId', 'orderCode'],
      },
    },

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/mcieunic/hybris-mcp-main'

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