Edit an Invoice Schedule

Update an existing invoice schedule, allowing changes to metadata, recurrence rules, or the schedule's active status.

Update an existing invoice schedule, allowing changes to metadata, recurrence rules, or the schedule's active status.

Key Features

file-invoice-dollar
Invoice Details

Modify invoice details, including subtotal, tax, and lineItems.

play-circle
Schedule Control

Pause or resume a schedule by toggling the active status.

calendar-alt
Recurrence Rules

Change the recurrence rule (rule) to update the schedule's frequency and timing.

clock
Next Run Control

Clear or manually set the next_run_at field for resumed schedules.

Usage Guide

pause-circlePausing a Schedule
  • Set active=false to pause the schedule.
  • When paused, the next_run_at field will automatically be set to null.
  • No new invoices will be generated while the schedule is paused.
play-circleResuming a Schedule
  • Set active=true to resume a paused schedule.
  • A valid next_run_at date in the future must be provided when resuming.
  • Past dates for next_run_at will result in a validation error.

Response Structure

CodeResponseReason
200SuccessThe schedule was successfully updated.
400Bad RequestInvalid fields or missing required parameters.
422Validation ErrorDTSTART or next_run_at is in the past.
500Internal Server ErrorAn unexpected server error occurred.

Important Considerations

power-offActive Status
  • Pausing the schedule (active=false) prevents further invoices from being generated.
  • To resume the schedule, provide a new next_run_at date in the future.
repeatRecurrence Rules
  • Follow the iCalendar RRule format for the rule parameter.
  • A properly formatted DTSTART in the future is mandatory.
historyAudit Trail

All changes to the schedule, including updates to metadata and status changes, are logged for tracking purposes.

calendar-checkFuture Dates Only

Ensure all dates, such as next_run_at and DTSTART, are in the future to avoid validation errors.

Path Params
string
required

The ID of the invoice schedule to update.

Body Params
number

The total amount for the invoice.

string

The iCalendar RRule recurrence rule string.

boolean

Whether the schedule is active. Set to false to pause.

boolean

Whether to send email notifications when invoices are generated.

files
array of strings

Array of file IDs to attach to the schedule.

files
meta
object

Metadata for the invoice, including line items, tax, and other details.

Responses
200

Schedule successfully updated.

400

Bad Request - Invalid fields or missing required parameters.

422

Validation Error - DTSTART or next_run_at is in the past, or invalid field values.

500

Internal Server Error.

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here!