API v1
REST API voor Factuur.software. Onderdeel van het Pro-abonnement. JSON in en uit, Bearer-authenticatie.
Authenticatie
Stuur je API-sleutel mee in de Authorization-header:
Authorization: Bearer JOUW_SLEUTEL
Genereer je sleutel via Profiel, onder API toegang. De sleutel is één keer zichtbaar - daarna bewaren we alleen een hash. Kwijt? Trek hem in en genereer een nieuwe.
Rate limit
1000 requests per uur per gebruiker. Daarboven volgt HTTP 429.
Endpoints
| Methode | Pad | Omschrijving |
|---|---|---|
| GET | /api/v1/me | profiel, abonnement, features en verbruik |
| GET | /api/v1/invoices | facturen (niet-gearchiveerd); query: from, to (YYYY-MM-DD), limit (max 1000), offset |
| GET | /api/v1/invoices/{id} | één factuur met regels en klant |
| POST | /api/v1/invoices | maak factuur; invoice_number leeg = automatische nummering, lines optioneel |
| PUT | /api/v1/invoices/{id} | wijzig status, invoice_number, issue_date, due_date, notes of customer_id |
| DELETE | /api/v1/invoices/{id} | archiveert de factuur (fiscale bewaarplicht, geen definitieve verwijdering) |
| GET | /api/v1/customers | klanten; query: limit, offset |
| GET | /api/v1/customers/{id} | één klant |
| POST | /api/v1/customers | maak klant; name is verplicht |
| PUT | /api/v1/customers/{id} | wijzig klantvelden |
| DELETE | /api/v1/customers/{id} | verwijder klant; 409 zolang er nog facturen aan hangen |
| GET | /api/v1/expenses | uitgaven; query: from, to (YYYY-MM-DD), limit, offset |
| GET | /api/v1/expenses/{id} | één uitgave |
| POST | /api/v1/expenses | maak uitgave |
| PUT | /api/v1/expenses/{id} | wijzig uitgave; bedragen en btw worden herberekend |
| DELETE | /api/v1/expenses/{id} | verwijder uitgave |
Statuscodes
200/201gelukt401Bearer-token ontbreekt of is ongeldig403abonnement geeft geen API-toegang404niet gevonden409conflict, bijvoorbeeld klant met facturen verwijderen422ongeldige payload429rate limit overschreden
Voorbeelden
curl -H "Authorization: Bearer JOUW_SLEUTEL" https://factuur.software/api/v1/me
curl "https://factuur.software/api/v1/invoices?from=2026-01-01&limit=50" -H "Authorization: Bearer JOUW_SLEUTEL"
curl -X POST -H "Authorization: Bearer JOUW_SLEUTEL" -H "Content-Type: application/json" -d '{"customer_id":1,"lines":[{"description":"Consultancy","quantity":8,"unit_price":95,"tax_rate":21}]}' https://factuur.software/api/v1/invoices
curl -X PUT -H "Authorization: Bearer JOUW_SLEUTEL" -H "Content-Type: application/json" -d '{"status":"betaald"}' https://factuur.software/api/v1/invoices/123