e-Factura API (CIUS-RO UBL)

Validate Romanian e-Factura XML and get the exact failing rules, generate CIUS-RO UBL from simple JSON (parties auto-filled from the CUI), parse incoming invoices to English JSON, and render the PDF. It does not submit invoices to SPV; it prepares and checks them.

curl example

curl -X POST "https://api.howtoromania.io/v1/efactura/validate" -H "x-api-key: htr_demo" -H "content-type: application/xml" --data-binary @invoice.xml
curl -X POST "https://api.howtoromania.io/v1/efactura/generate" -H "x-api-key: $HTR_KEY" -H "content-type: application/json" \
  -d '{"number":"INV-1","seller":{"vatId":"DE123456789","name":"Acme GmbH","street":"Hauptstr 1","city":"Berlin","country":"DE"},"buyer":{"cui":"14399840"},"currency":"EUR","vatToRonRate":5.09,"lines":[{"name":"Consulting","quantity":10,"unitCode":"HUR","unitPrice":120,"vatCategory":"AE","vatRate":0}]}'

Free key: curl -X POST https://api.howtoromania.io/v1/keys -H "content-type: application/json" -d '{"email":"you@example.com","accept_terms":true}'

MCP example

{ "mcpServers": { "howtoromania": { "url": "https://api.howtoromania.io/mcp", "headers": { "Authorization": "Bearer htr_demo" } } } }

Ask your agent: “ANAF rejected this XML. Validate it and tell me exactly which rules fail and how to fix them.”

Endpoints and prices

ServiceEndpointCredits≈ EUR
Validate invoice XML
validated with ANAF's public validation service (CIUS-RO) + local checks, rule codes
POST /v1/efactura/validate
MCP validate_efactura
1€0.005
Generate invoice XML
CIUS-RO UBL from simple JSON; parties auto-filled from CUI; validated with ANAF's public validation service
POST /v1/efactura/generate
MCP generate_efactura
2€0.010
Parse invoice XML
UBL Invoice/CreditNote -> English JSON
POST /v1/efactura/parse
MCP parse_efactura
1€0.005
Invoice PDF
rendered with ANAF's public PDF service
POST /v1/efactura/pdf
MCP efactura_to_pdf
1€0.005

Prepaid packs (VAT included): €5 = 1,000 · €20 = 5,000 · €100 = 30,000 credits. 100 free credits per key, no subscription.

Why HowToRomania

  • English JSON, ready for code and AI agents
  • Companies, court cases, e-Factura and legislation in force in one API
  • REST and a remote MCP server with the same key
  • Pay per call (1 credit = €0.005), no subscription; errors are not billed
  • 100 free credits on every key

FAQ

Does it upload invoices to ANAF SPV?

No. It validates, generates, parses and renders. Uploading to SPV stays with your accounting software or your own SPV integration.

Which formats are supported?

UBL 2.1 Invoice and CreditNote per CIUS-RO.

How much does it cost?

Pay per successful call in credits (1 credit = €0.005). Every key gets 100 free credits. Packs: €5 = 1,000 credits, €20 = 5,000 credits, €100 = 30,000 credits. Prepaid, no subscription; errors and not-found are not billed.

Can I try it without signing up?

Yes. The demo key htr_demo works on 1-credit endpoints with a small daily limit per IP. A free key with 100 credits is one POST to /v1/keys.

Is this an official ANAF or government service?

No. HowToRomania is an independent service that reads public sources (ANAF, ONRC open data, BNR, portal.just.ro, legislatie.just.ro) and returns them as English JSON. It is not affiliated with or endorsed by any public authority. Information only; not legal or credit advice.