Factorial · Arazzo Workflow

Factorial Log Attendance Shift

Version 1.0.0

Confirm an employee, log a completed attendance shift, and read it back.

1 workflow 1 source API 1 provider
View Spec View on GitHub Human ResourcesHRISEmployee ManagementTime TrackingPayrollTime OffPerformance ManagementArazzoWorkflows

Provider

factorial

Workflows

log-attendance-shift
Log a completed attendance shift for an employee and confirm it.
Confirms the employee, creates a shift with explicit times, and reads it back.
3 steps inputs: clock_in, clock_out, employee_id, location_type, observations outputs: employeeId, shiftId
1
confirmEmployee
getEmployee
Confirm the target employee exists before logging a shift.
2
createShift
createShift
Create the attendance shift with the supplied clock-in and clock-out times.
3
confirmShift
getShift
Read the created shift back to confirm its stored times.

Source API Descriptions

Arazzo Workflow Specification

factorial-log-attendance-shift-workflow.yml Raw ↑
arazzo: 1.0.1
info:
  title: Factorial Log Attendance Shift
  summary: Confirm an employee, log a completed attendance shift, and read it back.
  description: >-
    Records a completed attendance shift (with explicit clock-in and clock-out
    times) for an employee, rather than live clocking. The workflow confirms the
    employee exists, creates the shift, and reads it back to confirm the stored
    times. This is the building block for back-office time corrections and
    bulk-import integrations. Every step spells out its request inline so the
    flow can be read and executed without opening the underlying OpenAPI
    description.
  version: 1.0.0
sourceDescriptions:
- name: factorialApi
  url: ../openapi/factorial-openapi.yml
  type: openapi
workflows:
- workflowId: log-attendance-shift
  summary: Log a completed attendance shift for an employee and confirm it.
  description: >-
    Confirms the employee, creates a shift with explicit times, and reads it
    back.
  inputs:
    type: object
    required:
    - employee_id
    - clock_in
    - clock_out
    properties:
      employee_id:
        type: integer
        description: The id of the employee the shift belongs to.
      clock_in:
        type: string
        description: The shift clock-in timestamp (ISO 8601 date-time).
      clock_out:
        type: string
        description: The shift clock-out timestamp (ISO 8601 date-time).
      observations:
        type: string
        description: An optional note about the shift.
      location_type:
        type: string
        description: The optional location type for the shift.
  steps:
  - stepId: confirmEmployee
    description: >-
      Confirm the target employee exists before logging a shift.
    operationId: getEmployee
    parameters:
    - name: id
      in: path
      value: $inputs.employee_id
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      employeeId: $response.body#/id
  - stepId: createShift
    description: >-
      Create the attendance shift with the supplied clock-in and clock-out
      times.
    operationId: createShift
    requestBody:
      contentType: application/json
      payload:
        employee_id: $steps.confirmEmployee.outputs.employeeId
        clock_in: $inputs.clock_in
        clock_out: $inputs.clock_out
        observations: $inputs.observations
        location_type: $inputs.location_type
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      shiftId: $response.body#/id
  - stepId: confirmShift
    description: >-
      Read the created shift back to confirm its stored times.
    operationId: getShift
    parameters:
    - name: id
      in: path
      value: $steps.createShift.outputs.shiftId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      shiftId: $response.body#/id
  outputs:
    employeeId: $steps.confirmEmployee.outputs.employeeId
    shiftId: $steps.confirmShift.outputs.shiftId