Coopen Free audit →

Coopen / Work / Invoice approval

Client case study

Supplier invoices that arrive by email, approved without retyping a line.

BetSupplier receives Colombian electronic invoices — UBL 2.1, the DIAN format — from its suppliers, by email. Coopen built the system that pulls them in, reads the XML, matches every line to the client's own product codes and moves each invoice through an approval flow that keeps its history.

UBL 2.1DIAN electronic invoices, parsed
Gmailinvoices pulled straight from email
Fullapproval trail with state history
EdgeCloudflare Workers · D1 · Pages
Office worker reviewing a printed document at his desk

The challenge

Electronic invoicing does not remove the work — it moves it. The invoice arrives as a structured XML file that is perfectly readable by a machine and perfectly unreadable by a person, and someone still has to open the email, understand what came in, check it against what was ordered and approve it.

The expensive part is not the approval. It is the middle: every supplier names the same product differently, so matching an invoice line to the item in your own catalog is manual, repetitive and exactly the kind of work where a tired person makes a costly mistake.

What we built

What we built

  • Email intakeInvoices arrive by email and are ingested from Gmail — nobody downloads attachments by hand.
  • UBL 2.1 parserThe DIAN XML is parsed into real data: supplier, lines, totals, taxes. It's covered by tests, because a silent parsing error is the worst kind.
  • Product equivalencesThe supplier's product code is mapped to the client's own, so an invoice line matches the right item automatically instead of by eye.
  • Approval flowEach invoice moves through states with a recorded history — who moved it, when, and from what.
  • Suppliers & services registryThe counterparties and recurring services the invoices belong to, in one place.
  • Users and rolesSessions and permissions, so approval means something auditable.

Why the boring part is the valuable part

Any developer can render an invoice on a screen. What decides whether an invoice system actually saves money is the equivalence table — the unglamorous mapping between what your supplier calls a product and what you call it.

Get that right and approval becomes a glance. Get it wrong and you have built an expensive way to keep doing data entry.

The stack

Built on Cloudflare's edge

API on Workers, data on D1, interface on Pages. No server to patch, no invoice queue that stops because a machine ran out of disk.

Cloudflare Workers Hono D1 (SQL) Cloudflare Pages React UBL 2.1 / DIAN

Drowning in supplier invoices?

If your team is retyping what a machine already sent you in structured form, that is automatable today. Tell us what your invoices look like.