Sign Customiser

Navigation

Dark mode

Analytics

get_analytics_daily_counts

read

Get daily analytics counts

Copy page

Answer "how did the store trend day by day" with the same numbers the merchant admin charts show.

Overview

Returns the per-day counts the merchant admin dashboard and Analytics charts show for the connected Store: orders, products, quote requests, custom design enquiries, designs shoppers started with the AI sign designer, and how many of those designs are on an order now. It covers the last 1 to 90 calendar days (30 by default), oldest first, counted in an IANA timezone (UTC by default). Today is the last day and is still incomplete. Every day is listed, with zero counts on a day with nothing. It contains no customer personal data. It requires the analytics:read scope and has no side effects.

Permission

Requires theanalytics:readpermission. A connection without it answersinsufficient_scopenaming the permission to approve.

Annotations

readOnlyHinttrue
destructiveHintfalse
idempotentHinttrue
openWorldHintfalse

Prerequisites

  • A merchant has connected this store and approved the analytics:read scope.

Arguments

daysinteger

How many calendar days to report, from 1 to 90, today included. Defaults to 30.

timezonestring

The IANA timezone the days are counted in, such as Australia/Sydney. Defaults to UTC.

Result

The timezone the days were counted in and one row per calendar day, oldest first. The 30, 60 and 90 day order totals the merchant admin shows are sums of order_count over those days.

request_idstringalways present
storeobjectalways present
store.idintegeralways present
store.namestringalways present
timezonestringalways present

The IANA timezone the days were counted in.

daysarray of objectalways present

One row per calendar day, oldest first. The last row is today, which is still incomplete.

days[].datestringalways present

The calendar day in timezone, as YYYY-MM-DD.

days[].order_countintegeralways present
days[].product_countintegeralways present
days[].quote_countintegeralways present
days[].custom_design_countintegeralways present
days[].ai_design_countintegeralways present
days[].ordered_ai_design_countintegeralways present

Error cases

insufficient_scope

The connection was approved without analytics:read.

invalid_parameter

days is not an integer from 1 to 90, or timezone is not an IANA timezone name.

The last two days in Sydney

tools/call
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_analytics_daily_counts",
    "arguments": {
      "days": 2,
      "timezone": "Australia/Sydney"
    }
  }
}
result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "structuredContent": {
      "request_id": "req_01jz9x2k7c8f3m5n6p7q8r9s0t",
      "store": {
        "id": 12,
        "name": "Demo Signs"
      },
      "timezone": "Australia/Sydney",
      "days": [
        {
          "date": "2026-07-18",
          "order_count": 2,
          "product_count": 5,
          "quote_count": 1,
          "custom_design_count": 0,
          "ai_design_count": 3,
          "ordered_ai_design_count": 1
        },
        {
          "date": "2026-07-19",
          "order_count": 0,
          "product_count": 1,
          "quote_count": 0,
          "custom_design_count": 1,
          "ai_design_count": 0,
          "ordered_ai_design_count": 0
        }
      ]
    }
  }
}

A timezone that is not an IANA name (error)

tools/call
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_analytics_daily_counts",
    "arguments": {
      "days": 7,
      "timezone": "Sydney"
    }
  }
}
result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "isError": true,
    "structuredContent": {
      "error": {
        "code": "invalid_parameter",
        "title": "Invalid query parameter",
        "detail": "timezone must be an IANA timezone name, such as Europe/London.",
        "recovery": "Correct the parameter named in parameter. days is an integer from 1 to 90, and timezone is an IANA timezone name, such as Europe/London; days are counted in that timezone.",
        "parameter": "timezone"
      }
    }
  }
}

Type a question and press Enter. Use the arrow keys to move between the results.