Skip to main content
Glama

Push External Sales Orders

push_external_sales_orders
Idempotent

Push sales orders fulfilled OUTSIDE Spark for an External warehouse. They feed demand velocity without touching on-hand (the snapshot stays the inventory authority). Idempotent: each order is keyed by its stable externalOrderId — re-pushing the same id is a no-op.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "warehouseId": "<warehouseId>",
      "orders": "<orders>"
    },
    "name": "push_external_sales_orders"
  }
}

Input Schema

NameRequiredDescriptionDefault
ordersYesOrders: externalOrderId (stable dedup key), customer fields, lines (identifier/quantity/price).
previewNoStep 1 of the required two-step write: set true to validate and receive a structured resolution preview (matched/unmatched identifiers, already-pushed order ids) plus a single-use previewReceipt. Nothing is written until the commit call.
warehouseIdYesThe External warehouse id (GUID).
idempotencyKeyNoCaller-generated idempotency key; required with previewReceipt to commit.
previewReceiptNoStep 2 of the required two-step write: the receipt returned by the preview call. Supply together with a fresh idempotencyKey to commit; calls without it are refused.

Output Schema

NameRequiredDescriptionDefault
okNo
dataNo
previewNo
expiresAtNo
actionItemIdNo
confirmationNo
correlationIdNo
approvalResultNo
idempotencyKeyNo
previewReceiptNo
idempotentReplayNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, idempotentHint=true and destructiveHint=false, but the description adds real context beyond them: these orders 'feed demand velocity without touching on-hand (the snapshot stays the inventory authority)', which tells the agent what side effects to expect and which are absent. It also explains the mechanism behind idempotency (dedup keyed on stable externalOrderId), rather than just asserting the hint.

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

Conciseness5/5

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

Three short sentences, each earning its place: what it does, what it affects, and how repetition is handled. The scope qualifier is front-loaded and the idempotency caveat is placed where a caller will see it before invoking.

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

Completeness4/5

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

With an output schema present, annotations covering the safety profile, and full schema descriptions, the definition is close to complete. Residual gaps are operational rather than definitional: no mention of batch-size/rate limits for the orders array and no stated precondition that the External warehouse or feed must already exist.

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%, including the two-step preview/previewReceipt/idempotencyKey protocol, so the schema already carries the heavy lifting. The description only reinforces externalOrderId as the dedup key, which the schema states verbatim; it adds no new meaning for warehouseId, orders contents, or the preview receipt flow.

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

Purpose5/5

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

States a specific verb and resource ('Push sales orders') plus a decisive scope qualifier ('fulfilled OUTSIDE Spark for an External warehouse') that separates it from Spark-fulfilled creation paths. An agent can distinguish this from create_sales_order or import_historical_sales_orders without opening either schema.

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

Usage Guidelines3/5

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

Usage is implied by the scope qualifier rather than stated: the reader infers this is the path for externally fulfilled orders. There is no explicit when-not guidance (e.g. 'for Spark-fulfilled orders use create_sales_order') and no mention of prerequisites such as the External warehouse or feed being set up (get_external_feed_status exists as a plausible precondition).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources