Tickets API
POST/api/v1/tickets/recurring
Product availabilityAlgaPSAAlgaDesk

Create a recurring ticket definition

Creates a schedule that creates a ticket every time it falls due, for example "every year on 1 March, created 30 days early". What the ticket looks like (title, description, checklist, tags, board, priority) comes from a ticket template: create one first with POST /api/v1/tickets/templates and pass its template_id as ticket_template_id; ticket content fields such as title are rejected here with 400. recurrence.frequency is daily, weekly, monthly or yearly; a yearly rule is { frequency: "yearly", month, day, end } and means every year (it has no interval). A new definition generates nothing until clients are added with POST /api/v1/tickets/recurring/{definitionId}/clients. Use POST /api/v1/tickets/recurring/preview to check the dates first. Requires recurring_ticket:create and ticket_template:read. Returns 201 with definition, clients (each with client_id, client_name, is_active and asset_ids), next_due_at, time_zone and effective_fields.

RBAC · recurring_ticket

Request body

Content type: application/json · schema WorkV1RecurringTicketDefinitionBody

namestringRequired
Name of the schedule, for example "Apple APNs certificate renewal". It is not the ticket title; the title comes from the ticket template.
min length 1 · max length 200
is_activeboolean
Whether the schedule generates tickets. A definition only generates tickets for the clients added to it. Default true.
default true
ticket_template_idstring <uuid>Required
Ticket template this schedule creates tickets from: it supplies the title, description, checklist, tags and default board, priority and category. Create one with POST /api/v1/tickets/templates first.
overridesobject
Overrides of the template for the whole schedule: board, priority, category and assignment groups. Each group present replaces that group of template fields; absent groups inherit. Default {}.
default {}
boardobject
Override board and status together.
board_idstring <uuid>Required
Board for created tickets.
status_idstring <uuid>RequiredNullable
Status on that board; null for the board default.
priorityobject
Override the priority.
priority_idstring <uuid>Required
Priority for created tickets.
categoryobject
Override category and subcategory together.
category_idstring <uuid>RequiredNullable
Category; null for none.
subcategory_idstring <uuid>RequiredNullable
Subcategory; requires a category.
assignmentobject
Override assignment (assignee, team and additional agents) as a unit.
assigned_tostring <uuid>RequiredNullable
Assignee user UUID; null means unassigned.
assigned_team_idstring <uuid>RequiredNullable
Assigned team UUID; null for none.
additional_agent_idsarray of stringRequired
Additional agent user UUIDs.
itemsstring <uuid>
status_idstring <uuid>Nullable
Status for created tickets; must belong to the effective board. Null uses the board default.
default null
assigned_tostring <uuid>Nullable
User created tickets are assigned to. Null leaves them unassigned.
default null
assigned_team_idstring <uuid>Nullable
Team created tickets are assigned to. Null for none.
default null
additional_agent_idsarray of string
Additional agent user UUIDs on created tickets. Default [].
default []
itemsstring <uuid>
recurrenceoneOfRequired
oneOf (option 1)object
frequencystringRequired
Enum: daily
intervalintegerRequired
Repeat every N units (days, weeks or months). Not used by yearly rules.
≥ 1 · ≤ 999
weekdaysOnlyboolean
Only weekdays (Mon-Fri); requires interval 1. Default false.
default false
endoneOf
When the recurrence stops.
oneOf (option 1)object
The schedule never ends.
typestringRequired
Enum: never
oneOf (option 2)object
Ends on a date.
typestringRequired
Enum: onDate
datestringRequired
Last date, YYYY-MM-DD.
pattern /^\d{4}-\d{2}-\d{2}$/
oneOf (option 3)object
Ends after a number of occurrences.
typestringRequired
Enum: afterCount
countintegerRequired
Total number of occurrences.
≥ 1 · ≤ 10000
oneOf (option 2)object
frequencystringRequired
Enum: weekly
intervalintegerRequired
Repeat every N units (days, weeks or months). Not used by yearly rules.
≥ 1 · ≤ 999
weekdaysarray of stringRequired
Weekdays it recurs on, unique, at least one.
min items 1
itemsstring
Enum: montuewedthufrisatsun
endoneOf
When the recurrence stops.
oneOf (option 1)object
The schedule never ends.
typestringRequired
Enum: never
oneOf (option 2)object
Ends on a date.
typestringRequired
Enum: onDate
datestringRequired
Last date, YYYY-MM-DD.
pattern /^\d{4}-\d{2}-\d{2}$/
oneOf (option 3)object
Ends after a number of occurrences.
typestringRequired
Enum: afterCount
countintegerRequired
Total number of occurrences.
≥ 1 · ≤ 10000
oneOf (option 3)object
frequencystringRequired
Enum: monthly
intervalintegerRequired
Repeat every N units (days, weeks or months). Not used by yearly rules.
≥ 1 · ≤ 999
ononeOfRequired
oneOf (option 1)object
typestringRequired
Enum: dayOfMonth
dayanyOfRequired
anyOf (option 1)integer
≥ 1 · ≤ 31
anyOf (option 2)string
Enum: last
oneOf (option 2)object
typestringRequired
Enum: nthWeekday
nthanyOfRequired
anyOf (option 1)number
Enum: 1
anyOf (option 2)number
Enum: 2
anyOf (option 3)number
Enum: 3
anyOf (option 4)number
Enum: 4
anyOf (option 5)string
Enum: last
weekdaystringRequired
Enum: montuewedthufrisatsun
endoneOf
When the recurrence stops.
oneOf (option 1)object
The schedule never ends.
typestringRequired
Enum: never
oneOf (option 2)object
Ends on a date.
typestringRequired
Enum: onDate
datestringRequired
Last date, YYYY-MM-DD.
pattern /^\d{4}-\d{2}-\d{2}$/
oneOf (option 3)object
Ends after a number of occurrences.
typestringRequired
Enum: afterCount
countintegerRequired
Total number of occurrences.
≥ 1 · ≤ 10000
oneOf (option 4)object
frequencystringRequired
Every year, on the given month and day. Has no interval.
Enum: yearly
monthintegerRequired
Month of the year, 1-12.
≥ 1 · ≤ 12
dayintegerRequired
Day of the month; must exist in that month (Feb 29 clamps to Feb 28 in non-leap years).
≥ 1 · ≤ 31
endoneOf
When the recurrence stops.
oneOf (option 1)object
The schedule never ends.
typestringRequired
Enum: never
oneOf (option 2)object
Ends on a date.
typestringRequired
Enum: onDate
datestringRequired
Last date, YYYY-MM-DD.
pattern /^\d{4}-\d{2}-\d{2}$/
oneOf (option 3)object
Ends after a number of occurrences.
typestringRequired
Enum: afterCount
countintegerRequired
Total number of occurrences.
≥ 1 · ≤ 10000
start_datestringRequired
First date the schedule can fall on, YYYY-MM-DD. For a yearly rule this is the first year it is due.
pattern /^\d{4}-\d{2}-\d{2}$/
create_timestring
Wall-clock time (HH:MM, tenant time zone) the ticket is created on its create date. Default 08:00.
default "08:00"
due_timestring
Wall-clock time (HH:MM, tenant time zone) on the due date the ticket is due. Default 17:00.
default "17:00"
lead_daysinteger
How many days before the due date the ticket is created. 30 creates it a month ahead. Default 0.
default 0 · ≥ 0 · ≤ 365
non_business_day_policystring
When the due date is not a business day: 'keep' it, move to the 'previous' business day, or the 'next' one. Default keep.
default "keep"
Enum: keeppreviousnext
open_previous_policystring
'always_create' makes a new ticket even if the previous one is still open; 'skip' skips the occurrence while one is open. Default always_create.
default "always_create"
Enum: always_createskip
notify_client_on_createboolean
Send the usual new-ticket notification to the client contact when a ticket is created. Default false.
default false

Response body

Success response 201 · schema WorkV1ApiSuccess

dataanyOfRequired
anyOf (option 1)object
anyOf (option 2)array of object
itemsobject
metaobject

Response codes

201
The created definition (no clients yet).
400
Validation failure, an invalid id, or a reference that does not exist.
401
API key missing/invalid.
403
RBAC denied for recurring_ticket create.
500
Unexpected controller/service failure.