AutomationFlowsE-commerce › Automatically Store Shopify Orders in Google Sheets with Telegram Notifications

Automatically Store Shopify Orders in Google Sheets with Telegram Notifications

ByRedOne @redone on n8n.io

This workflow is designed for e-commerce store owners, operations managers, and developers who use Shopify as their e-commerce platform and want an automated way to track and analyze their order data.

Webhook trigger★★★★☆ complexity9 nodesGoogle SheetsTelegram
E-commerce Trigger: Webhook Nodes: 9 Complexity: ★★★★☆ Added:

This workflow corresponds to n8n.io template #4084 — we link there as the canonical source.

This workflow follows the Google Sheets → Telegram recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "id": "VcGLTfb4lc3iScZ0",
  "name": "Automatically Store Shopify Orders in Google Sheets with Telegram Notifications",
  "tags": [],
  "nodes": [
    {
      "id": "d0e405d1-9ad9-4983-bb59-fc50e62f3866",
      "name": "Workflow Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -140,
        420
      ],
      "parameters": {
        "color": "rgba(155, 89, 182, 1)",
        "width": 500,
        "height": 480,
        "content": "## Shopify to Google Sheets Order Tracking with Telegram Notifications\n\nThis workflow captures incoming Shopify orders via webhook, automatically stores them in a Google Sheet for tracking and analysis, and sends instant notifications to Telegram.\n\n### Setup Required:\n- Shopify store with webhook configured to this n8n webhook URL\n- Google Sheets account with a prepared order tracking spreadsheet\n- Telegram bot and chat ID for notifications\n- Configure the Edit Variables node with your specific settings\n\n### How it works:\n1. Webhook receives order data from Shopify\n2. Data is transformed into a consistent format\n3. Processed orders are saved to your Google Sheet\n4. Notifications are sent to your Telegram chat"
      },
      "typeVersion": 1
    },
    {
      "id": "ff4bd186-2677-44db-abfe-a0c5356f170a",
      "name": "Receive New Shopify Order",
      "type": "n8n-nodes-base.webhook",
      "position": [
        460,
        760
      ],
      "parameters": {
        "path": "shopify-webhook",
        "options": {},
        "httpMethod": "POST"
      },
      "typeVersion": 2
    },
    {
      "id": "aee86e48-3921-46b8-85cf-fb34b4de693b",
      "name": "Transform Order Data to Standard Format",
      "type": "n8n-nodes-base.function",
      "position": [
        780,
        560
      ],
      "parameters": {
        "functionCode": "// Extract and standardize Shopify order data\nconst eventData = $input.item.json;\nconst orderData = eventData.body; // This is the actual Shopify order object\n\n// Extract customer info while preserving format\nlet customerName = '';\nif (orderData.shipping_address && orderData.shipping_address.name) {\n  customerName = orderData.shipping_address.name;\n} else if (orderData.billing_address && orderData.billing_address.name) {\n  customerName = orderData.billing_address.name;\n} else if (orderData.customer) {\n  // Concatenate first and last name, handling cases where one might be missing\n  const firstName = orderData.customer.first_name || '';\n  const lastName = orderData.customer.last_name || '';\n  customerName = `${firstName} ${lastName}`.trim();\n}\n\n// Ensure line_items exists and is an array\nconst rawLineItems = Array.isArray(orderData.line_items) ? orderData.line_items : [];\n\n// Transform to standardized format\nconst standardizedOrder = {\n  orderId: orderData.id || '',\n  orderNumber: orderData.order_number || '',\n  created_at: orderData.created_at || new Date().toISOString(),\n  processed: false, // Defaulting as per your desired structure\n  processed_at: '',\n  customer: {\n    name: customerName,\n    email: orderData.email || '',\n    phone: (orderData.shipping_address && orderData.shipping_address.phone) ||\n           (orderData.billing_address && orderData.billing_address.phone) || \n           (orderData.customer && orderData.customer.phone) || \n           ''\n  },\n  shippingAddress: {\n    name: (orderData.shipping_address && orderData.shipping_address.name) || customerName,\n    address1: (orderData.shipping_address && orderData.shipping_address.address1) || '',\n    address2: (orderData.shipping_address && orderData.shipping_address.address2) || '',\n    city: (orderData.shipping_address && orderData.shipping_address.city) || '',\n    province: (orderData.shipping_address && orderData.shipping_address.province) || '',\n    zip: (orderData.shipping_address && orderData.shipping_address.zip) || '',\n    country: (orderData.shipping_address && orderData.shipping_address.country_code) || ''\n  },\n  lineItems: rawLineItems.map(item => ({\n    id: item.id || '',\n    productId: item.product_id || '',\n    variantId: item.variant_id || '',\n    sku: item.sku || '', \n    name: item.name || item.title || '',\n    quantity: item.quantity || 1,\n    price: item.price || '0.00',\n    supplier: null,\n    fulfillment_status: item.fulfillment_status || 'unfulfilled',\n    tracking_number: null\n  })),\n  totalPrice: orderData.total_price || '0.00',\n  currency: orderData.currency || 'USD',\n  json: JSON.stringify(orderData) // Store the full original order for reference\n};\n\n// Convert objects to strings for Google Sheets\nstandardizedOrder.customer = JSON.stringify(standardizedOrder.customer);\nstandardizedOrder.shippingAddress = JSON.stringify(standardizedOrder.shippingAddress);\nstandardizedOrder.lineItems = JSON.stringify(standardizedOrder.lineItems);\n\nreturn {json: standardizedOrder};"
      },
      "typeVersion": 1
    },
    {
      "id": "f505d25f-dbd0-4d03-b2c8-9d62891decf8",
      "name": "Save Order to Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1060,
        520
      ],
      "parameters": {
        "columns": {
          "value": {},
          "schema": [],
          "mappingMode": "autoMapInputData",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1985380983,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/16hLaVyq09dvPpIKC4OmcRnzxa6-rR5h7eOBeDk28hnc/edit#gid=1985380983",
          "cachedResultName": "Order"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "16hLaVyq09dvPpIKC4OmcRnzxa6-rR5h7eOBeDk28hnc",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/16hLaVyq09dvPpIKC4OmcRnzxa6-rR5h7eOBeDk28hnc/edit?usp=drivesdk",
          "cachedResultName": "Daily Orders Sheet"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "ad495370-6fde-469b-802e-df03e44d1a36",
      "name": "Success?",
      "type": "n8n-nodes-base.if",
      "position": [
        1260,
        520
      ],
      "parameters": {
        "conditions": {
          "boolean": [
            {
              "value1": true,
              "value2": true
            }
          ]
        }
      },
      "typeVersion": 1
    },
    {
      "id": "be410e7d-ab51-4a74-889d-10100f90cb30",
      "name": "Send Error Notification",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1640,
        840
      ],
      "parameters": {
        "text": "\u274c *ERROR: Shopify Order Processing Failed*\n\n```\n{{ $json.error }}\n```\n\n*Error occurred at:* {{ $now }}",
        "chatId": "={{$node[\"Variables\"].json.telegramChatId}}",
        "additionalFields": {}
      },
      "credentials": {
        "telegramApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "e880a4ef-cc42-4de3-83c9-62275aabfaf2",
      "name": "Error Handling Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1160,
        220
      ],
      "parameters": {
        "color": "rgba(255, 153, 0, 1)",
        "content": "## Error Handling\n\nThis section checks if the Google Sheets operation was successful and sends appropriate notifications via Telegram.\n\nMake sure to configure a Telegram bot and set your chat ID in the Edit Variables node."
      },
      "typeVersion": 1
    },
    {
      "id": "99cae8a6-38e2-481c-8f36-3b434c8a8117",
      "name": "Send Success Notification1",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1680,
        320
      ],
      "parameters": {
        "text": "=\ud83d\udecd\ufe0f New Order Successfully Recorded\n\nOrder #: {{ $node[\"Transform Order Data to Standard Format\"].json.orderNumber }}\nCustomer: {{ JSON.parse($node[\"Transform Order Data to Standard Format\"].json.customer).name }}\nTotal: {{ $node[\"Transform Order Data to Standard Format\"].json.currency }} {{ $node[\"Transform Order Data to Standard Format\"].json.totalPrice }}\nDate: {{ $node[\"Transform Order Data to Standard Format\"].json.created_at }}\n\nOrder has been added to your Order Tracking Sheet.",
        "chatId": "=Your Telegram Chat Id",
        "additionalFields": {}
      },
      "credentials": {
        "telegramApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "a8b5532a-44c8-4f2a-a54a-a9e03d321141",
      "name": "Variables",
      "type": "n8n-nodes-base.set",
      "position": [
        480,
        500
      ],
      "parameters": {
        "values": {
          "string": [
            {
              "name": "spreadsheetId",
              "value": "Your Google Sheet Id"
            },
            {
              "name": "sheetName",
              "value": "orders"
            },
            {
              "name": "telegramChatId",
              "value": "Your Telegram Chat Id"
            }
          ]
        },
        "options": {}
      },
      "typeVersion": 2
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "e94d8900-ca57-4128-bbfa-879bb9b378ab",
  "connections": {
    "Success?": {
      "main": [
        [
          {
            "node": "Send Success Notification1",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Send Error Notification",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Variables": {
      "main": [
        []
      ]
    },
    "Receive New Shopify Order": {
      "main": [
        [
          {
            "node": "Transform Order Data to Standard Format",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Save Order to Google Sheets": {
      "main": [
        [
          {
            "node": "Success?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Transform Order Data to Standard Format": {
      "main": [
        [
          {
            "node": "Save Order to Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This workflow is designed for e-commerce store owners, operations managers, and developers who use Shopify as their e-commerce platform and want an automated way to track and analyze their order data.

Source: https://n8n.io/workflows/4084/ — original creator credit. Request a take-down →

More E-commerce workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

E-commerce

This workflow provides a robust, end-to-end automated pipeline for managing e-commerce orders. It bridges the gap between your storefront and your fulfillment team by handling inventory validation, mu

Gmail, Slack, Google Sheets
E-commerce

This n8n workflow helps Shopify store owners and teams automatically confirm orders via WhatsApp. It checks if the customer's number is valid using Rapiwa API, sends a personalized message, and logs e

HTTP Request, Google Sheets
E-commerce

This workflow is for online store owners, support teams, and marketing staff who want to automatically verify WhatsApp numbers and send order invoice links or personalized order updates to customers.

Google Sheets, N8N Nodes Rapiwa
E-commerce

This n8n workflow automates WooCommerce order processing by capturing order updates via webhook and converting them into Discord notifications and Google Sheets entries.

Discord, Google Sheets
E-commerce

This workflow automates inventory management and predictive reordering for Shopify stores. It integrates Shopify, Google Sheets, and Slack to monitor inventory levels, calculate dynamic reorder points

Shopify, Google Sheets, Gmail +2