{
  "name": "Daily Sales Digest — One Message, Full Picture",
  "description": "Every evening your phone gets revenue, order count, top product and a comparison against the same day last week.",
  "type": "GROWAIFY_SAMPLE",
  "notice": "Public preview — 2 of 5 nodes, connections removed. The full, working workflow is delivered after purchase at https://growaify.com/templates/",
  "nodes_total_in_full_version": 5,
  "category": "Operations",
  "price_usd": 19,
  "nodes": [
    {
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "cronExpression",
              "expression": "0 22 * * *"
            }
          ]
        }
      },
      "name": "Daily 22:00",
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1.2,
      "position": [
        -420,
        0
      ],
      "id": "h000001-0000-4000-8000-000000000001"
    },
    {
      "parameters": {
        "operation": "executeQuery",
        "query": "SELECT COALESCE(SUM(CASE WHEN created_at::date = CURRENT_DATE THEN total END),0) AS today, COALESCE(SUM(CASE WHEN created_at::date = CURRENT_DATE - 7 THEN total END),0) AS last_week, COUNT(CASE WHEN created_at::date = CURRENT_DATE THEN 1 END) AS orders FROM orders WHERE status = 'paid';"
      },
      "name": "Today vs Last Week",
      "type": "n8n-nodes-base.postgres",
      "typeVersion": 2.4,
      "position": [
        -200,
        0
      ],
      "id": "h000002-0000-4000-8000-000000000002",
      "credentials": {
        "postgres": {
          "id": "REPLACE_WITH_YOUR_POSTGRES_CRED",
          "name": "Database"
        }
      }
    }
  ],
  "connections": {},
  "meta": {
    "growaify_template": "sales-digest",
    "sample": true,
    "buy": "https://growaify.com/templates/"
  }
}