Library / Files & Cloud Storage
Files & Cloud Storage
Reconcile and approve CSV imports with Google Sheets, Drive, and Gmail
When you run it, it manages files using Gmail, Google Drive, Google Sheets.
What it does
## Reconcile an export before producing an import file ### How it works Download a CSV from Drive and compare it with Master. Separate new records, unchanged records, conflicting values, and invalid rows. Duplicate source IDs are all rejected. Invalid or conflicting batches stop for correction under a new batch ID; they are never partially exported. A clean batch waits for approval in Imports. After approval, read Master again. If it changed, mark the proposal stale instead of exporting it. Otherwise create a CSV containing only the new records in a private Drive folder. The source CSV and Master are not modified. ### Setup Run the demo first; its approval is simulated. Create Imports with these headers: case_key, payload_hash, proposal_hash, status, created_at, expires_at, summary, decision, reviewed_hash, reviewer, comment, output_file_id, draft_id. Create Master with record_id, email, due_date, amount. Upload a UTF-8 CSV with the same four headers. Connect Sheets, Gmail, and Drive with file creation access. Set spreadsheetId, outputFolderId, reportTo, and reviewerEmail, then disable demoMode. In Imports, enter approve, reject, or revise, copy proposal_hash to reviewed_hash, and fill reviewer with the configured email. Restrict sheet and folder access to trusted reviewers. ### Recovery Use a new batch ID after correcting a rejected file. Existing completed IDs stop; pending cases resume review. Output names include the proposal hash, allowing serial retries to reuse an existing file. Sheets does not provide a transactional lock: never run the same batch concurrently.
The steps
- Try complete demo
- Load fictional input
- Submit a case
- Configure workflow
- Use demo data
- Read case register
- Download source CSV
- Parse source CSV
- Read master
- Build proposal
- Already completed
- Existing case result
- Prepare register
- Demo review only
45 steps in total.
Similar automations
Finance, Invoices & AccountingReconcile bank payments to invoices and ERP using Postgres and Claude33 stepsFinance, Invoices & AccountingReconcile Rent Payments with an Excel Sheet and OpenAI11 stepsDocuments, PDF & OCRImport a CSV File from a URL into Excel12 stepsEmail AutomationReview, approve, and chase subcontractor change orders with forms, DeepSeek, Gmail, and37 steps