Skip to main content
POST
Create the offboarding of a leaver from an HR system event
Key: Write Scope: Company

Authorizations

Authorization
string
header
required

Use your Primo API key in the Authorization header as Bearer <API_KEY>.

Body

application/json
email
string<email>
required

An email address of the leaver, as Primo knows it

Pattern: ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
terminationDate

The leaver's last day (YYYY-MM-DD or ISO 8601). Defaults to the termination date already on the employee.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
data
object | null

Everything else the caller knows about the departure, as a free JSON object (reason, manager, equipment, who takes over…), at most 5000 characters once serialized. Written on the offboarding as its notes for the Offboarding Agent. May hold personal data.

Response

default - application/json
id
string
required
employeeId
string
required
isLegacy
boolean
required

Whether the offboarding runs on the steppers from before offboarding tickets

status
enum<string>
required
Available options:
PENDING,
SCHEDULED,
IN_PROGRESS,
CLOSED,
CANCELED
source
enum<string>
required
Available options:
COCKPIT,
MERGE,
KOMBO,
API
terminationDate
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
createdAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
ticketId
string | null

The offboarding ticket, whose tasks are its steps (getTicket)

ticketReference
string | null

The reference the cockpit shows for that ticket

stepModel
enum<string> | null

How the offboarding holds its steps: ACTIONS (the steppers from before offboarding tickets) or INTENTS (typed tasks under its ticket, run through the intent tools such as executeOffboardingConfirmationIntent). Null while it has neither a ticket nor a step.

Available options:
ACTIONS,
INTENTS
runBy
enum<string> | null

Who runs the offboarding, decided once at its creation: AGENT (the Offboarding Agent, on its own ticket) or CLASSIC (the ticket and steps of the offboarding settings). Null on one created before.

Available options:
AGENT,
CLASSIC
ticketWakeDate
string<date-time> | null

When the Offboarding Agent asked its ticket to wake it next; null while it sleeps on nothing.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
notes
string | null

Free text the admin or the caller wrote for the Offboarding Agent at its creation. May hold personal data: returned on a single offboarding only, never on getOffboardings.