Skip to main content
Glama

get_inventory_summary

Retrieve inventory summary for a product including quantities on hand, available, and reserved stock levels to monitor current inventory status.

Instructions

Get inventory summary for a product including quantities on hand, available, reserved, etc.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
productIdYesThe product ID (UUID)

Implementation Reference

  • Handler function that validates the productId argument and delegates to InflowClient.getProductSummary to fetch the inventory summary.
    async getProductSummary(client, args) {
      if (!args.productId) {
        return {
          success: false,
          error: 'productId is required'
        };
      }
    
      return await client.getProductSummary(args.productId);
    },
  • Input schema definition using Zod for the get_inventory_summary tool, specifying the required productId parameter.
    {
      description: 'Get inventory summary for a product including quantities on hand, available, reserved, etc.',
      inputSchema: {
        productId: z.string().describe('The product ID (UUID)')
      }
    },
  • index.js:108-127 (registration)
    MCP server registration of the get_inventory_summary tool, including schema and wrapper that calls the productHandlers handler and formats the response.
    server.registerTool(
      'get_inventory_summary',
      {
        description: 'Get inventory summary for a product including quantities on hand, available, reserved, etc.',
        inputSchema: {
          productId: z.string().describe('The product ID (UUID)')
        }
      },
      async (args) => {
        const result = await productHandlers.getProductSummary(inflowClient, args);
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(result, null, 2)
            }
          ]
        };
      }
    );
  • InflowClient helper method that makes the HTTP GET request to the Inflow API endpoint for product inventory summary (/products/{productId}/summary).
    async getProductSummary(productId) {
      try {
        const response = await this.client.get(
          `/${this.config.companyId}/products/${productId}/summary`
        );
    
        return {
          success: true,
          data: response.data
        };
      } catch (error) {
        return this._handleError(error, 'getProductSummary');
      }
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states this is a 'Get' operation, implying read-only behavior, but doesn't clarify permissions, rate limits, error handling, or response format. The description adds minimal context beyond the basic action, leaving gaps in understanding how the tool behaves in practice.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core purpose ('Get inventory summary for a product') and adds useful detail ('including quantities on hand, available, reserved, etc.'). There's no wasted text, making it appropriately sized for a simple tool, though it could be slightly more structured with usage hints.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description is incomplete for a tool that returns summary data. It mentions what data is included but doesn't describe the return structure, potential errors, or behavioral traits like idempotency. For a read operation with one parameter, it's minimally adequate but lacks depth needed for full agent understanding.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with the input schema fully documenting the 'productId' parameter as a UUID. The description adds no additional parameter semantics beyond what's in the schema (e.g., it doesn't explain format examples or constraints). Baseline 3 is appropriate since the schema handles the heavy lifting, but the description doesn't compensate or add value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Get inventory summary for a product' specifies the verb ('Get') and resource ('inventory summary'), with additional detail on what data is included ('quantities on hand, available, reserved, etc.'). It distinguishes itself from siblings like 'get_ingredient' or 'list_stock_adjustments' by focusing on summary data rather than individual records or lists, though it doesn't explicitly name alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing a valid product ID), exclusions, or compare it to siblings like 'search_ingredients' or 'list_stock_adjustments' for broader inventory queries. Usage is implied by the purpose but lacks explicit context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/intelligent-staffing-systems/mcp-inflow-ingredients'

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