Skip to main content

Example: Email-to-Data Pipeline

Scenario: You receive documents by email (invoices from vendors, contracts from partners, reports from field teams) and need to extract data from them automatically.

Overview

Email with PDF attachment → qomplement email inbox →
Email Inbox trigger → Parse document → Fill Excel template →
Send results email to your team

Setup

Step 1: Get your upload email address

  1. Go to Clouds in the sidebar
  2. Find your unique @qomplement.com email address
  3. Copy it

Step 2: Set up email forwarding

In your email client, create a rule to forward matching emails:

Gmail:

  1. Settings > Filters and Blocked Addresses > Create new filter
  2. From: vendor@example.com (or whatever matches)
  3. Has attachment: checked
  4. Forward to: your-id@qomplement.com

Outlook:

  1. Rules > New Rule
  2. From specific people + has attachment
  3. Forward to your-id@qomplement.com

Step 3: Build the workflow

  1. Go to Workflows > New Workflow
  2. Add an Email Inbox trigger node
  3. Connect a Parse Document node (select your extraction template)
  4. Connect an Excel Template node (select your spreadsheet template)
  5. Connect a Send Email node:
    • To: your-team@company.com
    • Subject: New document processed: {filename}
    • Attach: the filled Excel file
  6. Save and activate

Step 4: Test it

Send a test email with a document attachment to your upload address. Within minutes:

  1. The document appears in qomplement
  2. The workflow triggers
  3. Data is extracted and mapped to Excel
  4. Your team receives the filled spreadsheet by email

Advanced: Add routing

Use a Condition node to route documents differently:

Email arrives → Parse →
IF amount > $10,000 → Email to finance manager
ELSE → Email to accounting team

Or use Switch to handle different document types:

Email arrives → Parse →
SWITCH on document_type:
"invoice" → Fill Invoice Excel template → Email accounting
"contract" → Fill Contract Excel template → Email legal
"receipt" → Fill Expense Excel template → Email admin

Tips

  • Test the email forwarding before building the workflow — make sure documents arrive
  • Set up failure notifications on the workflow schedule so you know if something breaks
  • Start simple — get the basic pipeline working before adding conditions and branching