Recurring invoices
Invoices issued on a schedule.
Paths are relative to https://evenbooks.org/api/v1. How keys, errors, paging and versions work is in the guide; the whole reference is also an OpenAPI 3.1 document.
Administrator key marks endpoints that need a key with the admin role, Write access those a read-only key can’t call, and Idempotent those that accept an idempotency key.
List recurring invoices
/recurringEvery schedule, by name. List items omit occurrences, catchUp and templateTotal: get one schedule for those.
Response 200
array of ScheduleDto
Errors 400 · 401 · 403 · 404 · 409 · 429
Create a recurring invoice
/recurringA schedule issues an invoice for the customer on every occurrence from anchorDate (until endDate, if set), and emails it when sendEmail is on (to emailTo, or else the customer’s email). Give either contactId and template (the invoice lines), or fromInvoiceId to copy an issued invoice; its payment URL is copied only with copyPaymentUrl: true.
Request body
CreateScheduleInput
fromInvoiceIdstring · UuidcontactIdstring · Uuidnamestringrequiredfrequencystring · FrequencyrequiredOne of:
weeklybiweeklymonthlyquarterlysemiannuallyyearlyanchorDatestring · PlainDateStringrequiredendDatestring · PlainDateString or nulltermsDaysintegersendEmailbooleanemailTostring (email) or nulltemplateRecurringTemplateInputShow 5 fields
linesarray of DocumentLineInputrequireddocumentDiscountDiscountInput or nullmemostring or nullfooterstring or nullpaymentUrlstring or null
copyPaymentUrlboolean
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Get a recurring invoice
/recurring/{id}Includes the invoices issued so far (occurrences) and, for a paused schedule, the missed occurrences a catch-up resume would issue (catchUp).
Parameters
idstring (uuid)path · required
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Change a recurring invoice
/recurring/{id}Omitted fields stay as they are. A new template becomes a new template version used for future invoices only. Send version from your last read (409 version_conflict); cancelled schedules cannot change (409 invalid_state).
Parameters
idstring (uuid)path · required
Request body
UpdateScheduleInput
versionintegerrequirednamestringendDatestring · PlainDateString or nulltermsDaysintegersendEmailbooleanemailTostring (email) or nulltemplateRecurringTemplateInputShow 5 fields
linesarray of DocumentLineInputrequireddocumentDiscountDiscountInput or nullmemostring or nullfooterstring or nullpaymentUrlstring or null
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Cancel a recurring invoice
/recurring/{id}/cancelStops the schedule for good; invoices already issued stay as they are. Send version from your last read (409 version_conflict). The reason is kept in History.
Parameters
idstring (uuid)path · required
Request body
PostRecurringIdCancelBody
versionintegerrequiredreasonstringrequired
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Pause a recurring invoice
/recurring/{id}/pauseStops issuing until it is resumed. Active schedules only (409 invalid_state); send version from your last read (409 version_conflict).
Parameters
idstring (uuid)path · required
Request body
PostRecurringIdPauseBody
versionintegerrequired
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Resume a recurring invoice
/recurring/{id}/resumecatch_up issues every occurrence missed while paused, right away (listed in the schedule’s catchUp); skip never issues them and continues from the next one. Paused schedules only (409 invalid_state); send version from your last read (409 version_conflict).
Parameters
idstring (uuid)path · required
Request body
ResumeScheduleInput
versionintegerrequiredmodestringrequiredOne of:
catch_upskipidempotencyKeystring · IdempotencyKey
Response 200
ScheduleDto (fields under Schemas)
Errors 400 · 401 · 403 · 404 · 409 · 429
Issue due recurring invoices now
/recurring/{id}/runIssues every occurrence that is due today or earlier and has no invoice yet, as the scheduler would, and emails them if the schedule says so. Works on active and paused schedules; cancelled and completed ones issue nothing. Safe to repeat: an occurrence never gets a second invoice.
Parameters
idstring (uuid)path · required
Response 200
ScheduleRunResultDto
issuedarray of stringIds of the invoices issued by this run.
skippedExistingintegerDue occurrences that already had an invoice.
Errors 400 · 401 · 403 · 404 · 409 · 429
Schemas
The types these endpoints take or return, by name. Type names above link here.
DecimalString
decimal string
string
Discount
typestringOne of:
percentfixedvaluestring · NonNegativeDecimalString
DiscountInput
typestringrequiredOne of:
percentfixedvaluestring · NonNegativeDecimalStringrequired
DocumentLineInput
itemIdstring · Uuid or nulldescriptionstringrequiredquantitystring · NonNegativeDecimalStringunitPricestring · DecimalStringrequireddiscountDiscountInput or nullincomeAccountIdstring · UuidrequiredtaxRateIdsarray of string · Uuid
DocumentLineInputOutput
itemIdstring · Uuid or nulloptionaldescriptionstringquantitystring · NonNegativeDecimalStringunitPricestring · DecimalStringdiscountDiscount or nulloptionalincomeAccountIdstring · UuidtaxRateIdsarray of string · Uuid
Frequency
string
One of: weekly biweekly monthly quarterly semiannually yearly
IdempotencyKey
string
NonNegativeDecimalString
string
PlainDateString
string
RecurringTemplateInput
linesarray of DocumentLineInputrequireddocumentDiscountDiscountInput or nullmemostring or nullfooterstring or nullpaymentUrlstring or null
RecurringTemplateInputOutput
linesarray of DocumentLineInputOutputdocumentDiscountDiscount or nulloptionalmemostring or nulloptionalfooterstring or nulloptionalpaymentUrlstring or nulloptional
ScheduleDto
idstringnamestringstatusstring · ScheduleStatusOne of:
activepausedcancelledcompletedcontactIdstringcontactNamestringoptionalfrequencystring · FrequencyOne of:
weeklybiweeklymonthlyquarterlysemiannuallyyearlyanchorDatestring · PlainDateStringendDatestring · PlainDateString or nulltermsDaysintegersendEmailbooleanemailTostring or nulltemplateVersionintegertemplateRecurringTemplateInputOutputtemplateTotalstring · DecimalStringoptionallastIssuedIndexinteger or nulllastIssuedAtstring or nullnextOccurrenceDatestring · PlainDateString or nullnextRunAtstring or nullpausedAtstring or nullcreatedFromInvoiceIdstring or nulloccurrencesarray of ScheduleOccurrenceDtooptionalcatchUparray of ScheduleOccurrenceDtooptionalversionintegercreatedAtstring
ScheduleOccurrenceDto
indexintegerdatestring · PlainDateStringinvoiceIdstring or nullinvoiceNumberstring or nullinvoiceStatusstring or null
ScheduleStatus
string
One of: active paused cancelled completed
Uuid
string (uuid)