Platform modules
Tickets, service targets and escalation
Track ticket state, apply a versioned SLA policy and diagnose overdue work.
Create and follow a ticket
Tickets manages a subject, description, priority, reporter, optional assignee, comments and service-level targets. The main collection is /api/v1/tickets. Creation accepts title, optional description, priority, assignedToUserId and category; the default priority in the contract is Medium.
Create a development ticket, record its ID and number, then assign a responder. An unassigned ticket starts Open; a ticket assigned at creation starts InProgress. Assigning an Open ticket moves it to InProgress, and removing that assignment moves it back to Open.
Understand the lifecycle
Operation beneath /api/v1/tickets/{id} |
Behavior |
|---|---|
POST /assign |
Assign or unassign an Open or InProgress ticket |
POST /comments |
Add a comment unless the ticket is Closed |
POST /resolve |
Record the resolution; a Closed ticket must first be reopened |
POST /close |
Close a Resolved ticket |
POST /reopen |
Return to Open or InProgress according to assignment |
Invalid transitions return a conflict rather than silently changing state. Reopening clears resolution and closure timestamps and the resolution note. Deletion and restoration are separate from this service lifecycle; the module has trash and restore routes.
Configure a service-level policy
Create a policy with POST /api/v1/tickets/sla/policies. The contract includes category, priority, name, expected version, activation, first-response minutes, resolution minutes, organizational unit, escalation switch and optional fallback user.
The creation path matches the normalized category and priority to a current active policy. The ticket stores the policy ID, version and unit, and creates response and resolution deadlines from its creation time. Do not treat a later policy edit as a retroactive deadline change for existing tickets.
The first response is completed by an eligible responder's comment, not by the reporter commenting on their own ticket. Eligibility checks active user status, membership and both Permissions.Tickets.View and Permissions.Tickets.Respond in the policy unit. Grant this access through Organizations.
Follow escalation
The recurring tickets-sla-scan job is registered every minute. It records a breach, then chooses the assigned user if eligible or the configured fallback. If neither qualifies, the target becomes AwaitingRecipient and is scheduled for another check. If escalation is disabled, its state is recorded as Disabled.
Tickets:Sla:BatchSize defaults to 50 and RetryMinutes to 5 in the options class. The module validates batch sizes from 1 to 500 and retry intervals from 1 to 1440 minutes. Escalation publishes an integration event through the outbox; Notifications handles the inbox update.
Verify and troubleshoot
Inspect /api/v1/tickets/{id}/sla/history and /api/v1/tickets/sla/metrics. For an unmeasured ticket, check its category and priority against an active policy at creation. For missing escalation, check the job and outbox as well as responder eligibility.
Test resolution, closure and reopening; verify that a reporter's own comment does not satisfy the response target. Use a short development policy to observe a breach without modifying production deadlines. Reporting exposes ticket deadline and escalation columns for review.