KolayIK · Arazzo Workflow

Check balances and book leave in Kolay İK

Version 1.0.0

Resolve an employee, read their leave balances, check for overlapping leave in the window, create the leave record, and verify it.

1 workflow 1 source API 1 provider
View Spec View on GitHub CompanyHuman ResourcesHRPayrollHuman Capital ManagementEmployee ManagementTime and AttendanceApplicant TrackingSaaSTurkeyArazzoWorkflows

Provider

kolayik

Workflows

bookLeave
Book a leave request for an employee after checking balance and conflicts.
4 steps inputs: comment, endDate, leaveTypeId, personId, replacementPersonId, startDate outputs: leaveId
1
readBalances
personLeaveStatus
Read the employee's leave balances before booking anything.
2
checkOverlap
leaveList
List existing leave in the requested window to detect conflicts.
3
createLeave
leaveCreate
Create the leave record.
4
verifyLeave
leaveView
Read the created leave record back.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Check balances and book leave in Kolay İK
  version: 1.0.0
  summary: Resolve an employee, read their leave balances, check for overlapping leave
    in the window, create the leave record, and verify it.
  description: >-
    Every operationId below exists verbatim in openapi/kolayik-public-api-openapi.yml,
    which is a faithful conversion of the official Kolay Public API Postman collection.
    Kolay publishes no sandbox and no idempotency key — a retried createLeave books a
    second leave record.
sourceDescriptions:
- name: kolay
  url: ../openapi/kolayik-public-api-openapi.yml
  type: openapi
workflows:
- workflowId: bookLeave
  summary: Book a leave request for an employee after checking balance and conflicts.
  inputs:
    type: object
    required: [personId, leaveTypeId, startDate, endDate]
    properties:
      personId:
        type: string
        description: 32-character Kolay person id.
      leaveTypeId:
        type: string
        description: 32-character Kolay leave type id.
      startDate:
        type: string
        description: 'YYYY-MM-DD HH:MM:SS'
      endDate:
        type: string
        description: 'YYYY-MM-DD HH:MM:SS'
      comment:
        type: string
      replacementPersonId:
        type: string
  steps:
  - stepId: readBalances
    description: Read the employee's leave balances before booking anything.
    operationId: personLeaveStatus
    parameters:
    - name: id
      in: path
      value: $inputs.personId
    successCriteria:
    - condition: $statusCode == 200
  - stepId: checkOverlap
    description: List existing leave in the requested window to detect conflicts.
    operationId: leaveList
    parameters:
    - name: personId
      in: query
      value: $inputs.personId
    - name: startDate
      in: query
      value: $inputs.startDate
    - name: endDate
      in: query
      value: $inputs.endDate
    - name: status
      in: query
      value: approved
    - name: limit
      in: query
      value: '100'
    successCriteria:
    - condition: $statusCode == 200
  - stepId: createLeave
    description: Create the leave record.
    operationId: leaveCreate
    parameters:
    - name: personId
      in: query
      value: $inputs.personId
    - name: leaveTypeId
      in: query
      value: $inputs.leaveTypeId
    - name: startDate
      in: query
      value: $inputs.startDate
    - name: endDate
      in: query
      value: $inputs.endDate
    - name: comment
      in: query
      value: $inputs.comment
    - name: replacementPersonId
      in: query
      value: $inputs.replacementPersonId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      leaveId: $response.body#/data/id
  - stepId: verifyLeave
    description: Read the created leave record back.
    operationId: leaveView
    parameters:
    - name: leaveId
      in: path
      value: $steps.createLeave.outputs.leaveId
    successCriteria:
    - condition: $statusCode == 200
  outputs:
    leaveId: $steps.createLeave.outputs.leaveId