MIDAS API Addon MIDAS API: gen_invoice

Available in API 2.0+
Automatically generate invoices.

To generate an invoice from an existing booking:

Required ParametersPossible ValuesDescription
bookingBooking IDThe numeric ID of the existing booking for which to generate an invoice for
Example Response
{
	"invoice_created":"MIDAS00075"
}
Variables ReturnedDescription
invoice_createdThe Invoice number/reference of the newly generated invoice

To generate a series of invoices for bookings across a date range:

Required ParametersPossible ValuesDescription
startValid date and time
(Format: YYYYMMDDHHMM)
Sets the start of the window in which bookings should be included in generated invoices
endValid date and time
(Format: YYYYMMDDHHMM)
Sets the end of the window in which bookings should be included in generated invoices
Optional ParametersPossible ValuesDescription
clientClient IDThe numeric ID of the existing client who's bookings should be included on the generated invoice
Including the optional "client" parameter will limit invoice generation to a single invoice containing all bookings for the specified client which take place between the specified start/end values.

Omitting the optional "client" parameter will generate separate invoices for each client with bookings taking place between the specified start/end values.
Example Response
{
	"invoices_created":"MIDAS00076,MIDAS00077,MIDAS00078,MIDAS00079"
}
Variables ReturnedDescription
invoices_createdA comma-separated list of all newly generated invoices