---
name: woocommerce-daily-sales-report
description: "Every morning: yesterday's WooCommerce net sales, orders and average order value against the same day last week, with the best-selling products. Use when the user asks for this, or when it runs on a schedule."
---

# WooCommerce daily sales report

Every morning: yesterday's WooCommerce net sales, orders and average order value against the same day last week, with the best-selling products.

WooCommerce emails you about every order but never about the day. Store owners end up opening Analytics in wp-admin each morning, setting the date to yesterday and comparing it in their head with last week.

The agent reads yesterday's totals from WooCommerce Analytics, lines them up with the same weekday a week earlier, and adds the five products that sold best. The card lands before you open the laptop, and a slow day shows up next to its reason: fewer orders, smaller baskets, or a coupon that ran wider than planned.

## Two ways to get the data

Use the API or MCP route when you have an MCP server, a CLI or an API token for the app. Otherwise, if you can drive a browser the user is signed in to (Claude in Chrome, a Playwright or Chrome DevTools MCP server), use the browser route. Say which one you used.

## Route A: API or MCP server

### What you need

- A WooCommerce REST API key with Read permission (WooCommerce > Settings > Advanced > REST API), in `WC_CONSUMER_KEY` and `WC_CONSUMER_SECRET`, and the store URL on HTTPS.
- WooCommerce Analytics enabled (it is on by default). The WooCommerce MCP integration is in developer preview as of October 2026 and covers orders and products, not Analytics.

If something is missing, say what and stop; do not invent numbers.

### Steps

1. **Read yesterday and the 13 days before** (WooCommerce): Call `GET /wp-json/wc-analytics/reports/revenue/stats?interval=day&after=<14 days ago>T00:00:00&before=<yesterday>T23:59:59&per_page=14` with your consumer key and secret over HTTPS, using the store's local dates. Each entry in `intervals` has `subtotals` with `gross_sales`, `net_revenue`, `orders_count`, `coupons`, `refunds`, `shipping` and `taxes`.
2. **Work out the day**: Net sales is `net_revenue` (gross sales less coupons and refunds). Average order value is net sales divided by `orders_count`. Compare yesterday with the same weekday last week, since weekend and weekday sales differ more than any trend.
3. **Find the best sellers** (WooCommerce): Call `GET /wp-json/wc/v3/orders?after=<yesterday>T00:00:00&before=<yesterday>T23:59:59&status=processing,completed&per_page=100`, add up `line_items` by `product_id` (quantity and `total`), and keep the top 5. Note which `coupon_lines` codes were used most.
4. **Post the tile**: Net sales is the headline with 14 days of history; orders, average order value and refunds go in the glance, and the breakdown and top products in the opened card.

## Route B: the browser

### What you need

- Signed in to the store's WordPress admin with the Shop manager or Administrator role, which is what WooCommerce Analytics requires.

If something is missing, say what and stop; do not invent numbers.

### Steps

Start at https://example.com/wp-admin/admin.php?page=wc-admin&path=%2Fanalytics%2Frevenue. The user is signed in already; never type passwords or codes, and ask if a sign-in page appears.

1. **Open Analytics > Revenue in your own wp-admin**: The URL is on your own site, so replace `example.com` with the store's domain, or sign in to wp-admin and open **Analytics > Revenue**. Set **Date range** to a custom range covering the last 14 days ending yesterday and **Interval** to `Day`; the table under the chart gives one row per day with gross sales, returns, coupons, net sales, taxes, shipping and orders.
2. **Work out yesterday against the same weekday last week**: From the table take yesterday's row and the row seven days earlier. Net sales and orders come straight from the columns; average order value is net sales divided by orders. Give each number with its change.
3. **Find the best sellers and coupons**: Open **Analytics > Products**, set the date range to yesterday and sort the table by **Net sales** for the top 5. Then **Analytics > Coupons** for the same day to see which codes were used most.
4. **Write the tile**: Net sales is the headline with the 14 daily values from the Revenue table as history; orders, average order value and refunds (the returns column) go next to it, then the breakdown and the products. The **Download** button on each report gives a CSV when the table is long.

Note: Analytics uses the statuses and date type set under Analytics > Settings, so it can differ from the Orders list. The tables fill from a background import; if a day looks short, the Settings page has an **Import historical data** button that catches it up. Multi-site owners need one run per store.

## The report

- **Net sales** yesterday and the change on the same day last week, with 14 days of history.
- **Orders**, **average order value** and **refunds**, each with its change.
- **The breakdown**: gross sales, coupons, refunds, shipping and taxes.
- **Top 5 products** by revenue, and the coupon codes used most.
- One line on what moved the day.

## Post it to Briefkin

When `BRIEFKIN_TOKEN` is set, or `~/.config/briefkin/env` exists (the installer from https://briefkin.dev/docs writes it), also send the result to the user's Briefkin board as one card. Keep the `item_key` the same on every run so the card updates in place, use a new `event_id` per run, and put today's real numbers in place of the example ones. If the request fails, say so once and carry on.

```bash
[ -n "${BRIEFKIN_TOKEN:-}" ] || . ~/.config/briefkin/env
curl -sS -X POST "${BRIEFKIN_URL:-https://briefkin.dev}/v1/events" \
  -H "authorization: Bearer $BRIEFKIN_TOKEN" \
  -H "content-type: application/json" \
  -d @- <<'JSON'
{
  "v": 1,
  "event_id": "woocommerce-daily-sales-report/<date of this run, e.g. 2026-10-16>",
  "item_key": "woocommerce-daily-sales-report",
  "project": "Acme Store",
  "source": "WooCommerce daily sales report skill",
  "kind": "metric",
  "title": "Net sales $3,184 yesterday, up 14%",
  "metric": {
    "label": "Net sales",
    "value": 3184,
    "prefix": "$",
    "better": "higher",
    "period_start": "<start of the period, ISO 8601>",
    "period_end": "<end of the period, ISO 8601>"
  },
  "glance": [
    {
      "type": "Grid",
      "props": {
        "columns": 3
      },
      "children": [
        {
          "type": "Stat",
          "props": {
            "label": "Orders",
            "value": 41,
            "delta": 11
          }
        },
        {
          "type": "Stat",
          "props": {
            "label": "Avg order value",
            "value": 77.66,
            "prefix": "$",
            "delta": 3
          }
        },
        {
          "type": "Stat",
          "props": {
            "label": "Refunds",
            "value": 86,
            "prefix": "$",
            "better": "lower"
          }
        }
      ]
    }
  ],
  "widget": [
    {
      "type": "KeyValue",
      "props": {
        "items": [
          {
            "key": "Gross sales",
            "value": "$3,412"
          },
          {
            "key": "Coupons",
            "value": "-$142"
          },
          {
            "key": "Refunds",
            "value": "-$86"
          },
          {
            "key": "Net sales",
            "value": "$3,184"
          },
          {
            "key": "Shipping",
            "value": "$296"
          },
          {
            "key": "Taxes",
            "value": "$241"
          }
        ]
      }
    },
    {
      "type": "Table",
      "props": {
        "columns": [
          "Product",
          "Sold",
          "Revenue"
        ],
        "align": [
          "left",
          "right",
          "right"
        ],
        "rows": [
          [
            "Organic cotton tee",
            18,
            "$540"
          ],
          [
            "Canvas tote",
            12,
            "$336"
          ],
          [
            "Wool beanie",
            9,
            "$297"
          ],
          [
            "Ceramic mug",
            11,
            "$242"
          ],
          [
            "Linen apron",
            4,
            "$188"
          ]
        ]
      }
    },
    {
      "type": "Callout",
      "props": {
        "text": "The cotton tee sold 18 the day after the newsletter, and 9 of the 41 orders used the code FALL10.",
        "tone": "info"
      }
    }
  ],
  "size": "md"
}
JSON
```

Widgets come from the Briefkin catalog (https://briefkin.dev/v1/catalog). Without a token, just give the user the report.

Set `period_start` and `period_end` to the window the number covers: the tile names it from them ("Last 7 days", "Today", "This month"). For a count right now (open items, a balance), send `"period_label": ""` so no period shows; for another name, send it as `period_label` (at most 24 characters).

## Run it on a schedule

Suggested: Daily at 8:00 (`0 8 * * *`). From cron, with the agent signed in on that machine:

```bash
0 8 * * * claude -p "Run the woocommerce-daily-sales-report skill"
# Codex: codex exec, Gemini CLI: gemini -p, Copilot CLI: copilot -p, OpenCode: opencode run
```

Or use the agent's own scheduler (Claude Code routines, Codex automations, Claude or ChatGPT scheduled tasks): https://briefkin.dev/skills/woocommerce-daily-sales-report#schedule

Source: https://briefkin.dev/skills/woocommerce-daily-sales-report
