# Purchase Bill OCR to QuickBooks

**Category:** Finance  
**Tools:** QuickBooks, Extract Data, n8n  
**Nodes:** 20  
**Built by:** Forgent Systems

Upload supplier invoices and they become accurate QuickBooks bills, with no typing. AI extracts vendor, line items and totals, and anything missing in QuickBooks is created automatically.

![Workflow](preview.webp)

## How it works

1. Bills are uploaded through a form and text is extracted from each PDF.
2. AI reads the invoice into structured vendor and line-item data.
3. The vendor is looked up in QuickBooks and created if needed.
4. Line items are checked against existing products and new ones are added.
5. A complete bill is created in QuickBooks.

## Use cases

- Accounts payable teams
- Retail and wholesale purchasing
- Accounting outsourcing

## Setup

1. In n8n open **Workflows → Import from File** and choose `workflow.json`.
2. Connect these credentials:
   - OpenRouter account
   - QuickBooks Online account
3. Point the Sheets / Airtable / Drive / Slack nodes at your own resources (structure above).
4. Replace placeholder emails, phone numbers and `YOUR-FORM-ID` links with your own.
5. Times use the America/New_York timezone and dates use MM/DD/YYYY. Adjust if needed.
6. Run a test execution, then activate.

## Nodes

- **Split Items to Create** — `n8n-nodes-base.splitOut`
- **Create Items** — `n8n-nodes-base.httpRequest`
- **Merge Item Creation Paths** — `n8n-nodes-base.merge`
- **Collect All Item Mappings** — `n8n-nodes-base.code`
- **Find Vendor** — `n8n-nodes-base.quickbooks`
- **Vendor Exists?** — `n8n-nodes-base.if`
- **Create Vendor** — `n8n-nodes-base.quickbooks`
- **Create Bill ** — `n8n-nodes-base.httpRequest`
- **Need to Create Items?** — `n8n-nodes-base.if`
- **Get All QB Items** — `n8n-nodes-base.quickbooks`
- **Prepare Items to Check** — `n8n-nodes-base.code`
- **Extract Invoice Data** — `@n8n/n8n-nodes-langchain.informationExtractor`
- **Clean Text** — `n8n-nodes-base.code`
- **Loop Over Invoices** — `n8n-nodes-base.splitInBatches`
- **Convert to Separate Items** — `n8n-nodes-base.code`
- **Extract from PDF** — `n8n-nodes-base.extractFromFile`
- **Check Which Items to Create** — `n8n-nodes-base.code`
- **Build Bill Payload** — `n8n-nodes-base.code`
- **OpenRouter Chat Model** — `@n8n/n8n-nodes-langchain.lmChatOpenRouter`
- **On bill submission** — `n8n-nodes-base.formTrigger`
