Skip to main content
Glama

Get Sales Trend

get_orders_time_series
Read-only

Returns the company's store orders and sales over time in a date range, in daily or weekly buckets, for a sales trend or chart. start and end are full ISO 8601 timestamps such as 2026-04-01T00:00:00Z; omit both for the last 90 days. Call get_ecommerce_connection_status first and answer together with it: never report zero for a platform whose data is still syncing or not connected. It reads the active company; for another company the user owns, pass its companyId from list_companies instead of switching the active company.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_orders_time_series"
  }
}

Input Schema

NameRequiredDescriptionDefault
endNoOPTIONAL end as a FULL ISO 8601 timestamp WITH time + timezone, e.g. '2026-04-30T23:59:59Z'. Never date-only. Omit alongside `start` to fall back to the rolling 90-day window.
startNoOPTIONAL start as a FULL ISO 8601 timestamp WITH time + timezone, e.g. '2026-04-01T00:00:00Z'. Always include the time component and Z suffix — date-only strings (like '2026-04-01') are rejected by the upstream service. If the customer doesn't specify a date range, OMIT this and the tool defaults to the last 90 days.
contextNoOptional, for analytics only. In one sentence, why you are calling this tool and how it serves the user's goal. Describe the purpose in general terms: never include names, emails, phone numbers, addresses, IDs or any other personal details.
companyIdNoOPTIONAL. The doolaCompanyId (an id like '30E5c1AQA326uOuDlsic4No7zZ5'). LEAVE THIS EMPTY/UNSET to use the customer's currently active company — that is the correct default for almost every question. Pass a value ONLY when the customer explicitly references a *different* company they own (e.g. 'show me transactions for my other company X'). NEVER pass a company name, slug, or human label here — only an exact id string.
llm_modelNoOptional, for analytics only. Your exact model identifier from your system prompt (e.g. "claude-opus-4-8"), or "unknown" if unsure. Never guess.
conversation_idNoOptional, for analytics only. The exact conversation_id from this server's previous response, unchanged. The first response provides one, so leave this out until you have it and never invent one. Keep passing the same value for the rest of the conversation, even when the user moves on to a new request.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=false, yet the description adds substantive behavior: the rolling 90-day default when both dates are omitted, the false-zero hazard during sync, and active-company scoping versus explicit companyId. These are exactly the operational details annotations cannot express.

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?

Three front-loaded sentences with no filler; the purpose lands first, then the date convention, then the safety and scoping rules. Some sentences are clause-heavy, which slightly taxes scanning, but nothing is redundant.

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?

For a six-parameter, zero-required read tool with no output schema, the definition covers defaults, timestamp format, sync caveats and multi-company routing thoroughly. The only unresolved item is what determines daily versus weekly bucketing, which an agent may need in order to call it correctly.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds cross-field meaning the schema does not: start and end must be supplied or omitted together, and companyId should be sourced from list_companies rather than a name. One gap remains — it mentions daily or weekly buckets but never explains how granularity is selected, since no such parameter exists.

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?

The first sentence gives a specific verb (returns) plus resources (store orders and sales) with scope (date range, daily or weekly buckets) and intended use (sales trend or chart), which cleanly separates it from get_orders and get_ads_time_series. An agent can identify the tool without opening the schema.

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

Usage Guidelines5/5

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

Explicit routing is given: call get_ecommerce_connection_status first and answer together with it, never report zero for a platform that is syncing or not connected. It also names the alternative path for other companies (pass companyId from list_companies rather than switching the active company), so when-to-use and when-not-to-use are both covered.

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.