Payroll

Employees and payroll runs — employee records (a Counterparty extension), month payslip generation/approval, salary advances, and net/statutory settlement.

15 endpoints·Scopes: payroll:read, payroll:write
GET/api/employees#

List employees

scope · payroll:read

Lists employees the caller can see. Results are filtered by the caller's accessible organizations; many routes paginate via page and limit.

Scope: payroll:read
Endpoint: GET /api/employees

Example request

curl "https://app.guliel.com/api/employees?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • searchreq
    string
  • includeInactive
    enum<2>
    true · false

Response (200/201)

  • employeesreq
    array<object>
    • idreq
      stringThe Counterparty id — an employee is a Counterparty edge.
    • individualIdreq
      string | null
    • namereq
      string
    • emailreq
      string | null
    • dateOfBirthreq
      string | null
    • baseSalaryreq
      number | null
    • salaryCurrencyreq
      string | null
    • employmentStartreq
      string | null
    • employmentEndreq
      string | null
    • employmentDatareq
      object | null
    • activereq
      booleanNo employmentEnd, or an employmentEnd in the future.

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
POST/api/employees#

Create an employee

scope · payroll:writerole · CONTRIBUTOR+

Creates a new employee in the target organization. Returns the created record on success.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/employees

Example request

curl -X POST "https://app.guliel.com/api/employees" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "name": "Sample"
}'

Request body

  • organizationIdreq
    string
  • namereq
    string
  • email
    string | string
  • dateOfBirth
    string | null
  • baseSalary
    number
  • salaryCurrency
    string
  • employmentStart
    string | null
  • employmentEnd
    string | null
  • employmentData
    object

Response (200/201)

  • idreq
    stringThe Counterparty id — an employee is a Counterparty edge.
  • individualIdreq
    string | null
  • namereq
    string
  • emailreq
    string | null
  • dateOfBirthreq
    string | null
  • baseSalaryreq
    number | null
  • salaryCurrencyreq
    string | null
  • employmentStartreq
    string | null
  • employmentEndreq
    string | null
  • employmentDatareq
    object | null
  • activereq
    booleanNo employmentEnd, or an employmentEnd in the future.

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
DELETE/api/employees/{id}#

Delete an employee

scope · payroll:write

Deletes the employee. Some endpoints hard-delete the row, others soft-revoke (set revokedAt). Check the response shape.

Scope: payroll:write
Endpoint: DELETE /api/employees/{id}

Example request

curl -X DELETE "https://app.guliel.com/api/employees/abc123?id=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • idreq
    string
  • employmentEnd
    string

Response (200/201)

  • idreq
    stringThe Counterparty id — an employee is a Counterparty edge.
  • individualIdreq
    string | null
  • namereq
    string
  • emailreq
    string | null
  • dateOfBirthreq
    string | null
  • baseSalaryreq
    number | null
  • salaryCurrencyreq
    string | null
  • employmentStartreq
    string | null
  • employmentEndreq
    string | null
  • employmentDatareq
    object | null
  • activereq
    booleanNo employmentEnd, or an employmentEnd in the future.

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
PATCH/api/employees/{id}#

Update an employee

scope · payroll:write

Updates an existing employee. Only the fields present in the request body are changed; omitted fields stay as-is.

Scope: payroll:write
Endpoint: PATCH /api/employees/{id}

Example request

curl -X PATCH "https://app.guliel.com/api/employees/abc123" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "id": "abc123"
}'

Request body

  • idreq
    string
  • name
    string
  • email
    string | string
  • dateOfBirth
    string | null
  • baseSalary
    number | null
  • salaryCurrency
    string | null
  • employmentStart
    string | null
  • employmentEnd
    string | null
  • employmentData
    object

Response (200/201)

  • idreq
    stringThe Counterparty id — an employee is a Counterparty edge.
  • individualIdreq
    string | null
  • namereq
    string
  • emailreq
    string | null
  • dateOfBirthreq
    string | null
  • baseSalaryreq
    number | null
  • salaryCurrencyreq
    string | null
  • employmentStartreq
    string | null
  • employmentEndreq
    string | null
  • employmentDatareq
    object | null
  • activereq
    booleanNo employmentEnd, or an employmentEnd in the future.

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/advance#

Run advance (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the advance operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/advance

Example request

curl -X POST "https://app.guliel.com/api/payroll/advance" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "counterpartyId": "abc123",
  "amount": 100,
  "paidAt": "string"
}'

Request body

  • organizationIdreq
    string
  • counterpartyIdreq
    string
  • amountreq
    number
  • paidAtreq
    string
  • method
    string

Response (200/201)

  • paymentIdreq
    string

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/apply#

Run apply (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the apply operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/apply

Example request

curl -X POST "https://app.guliel.com/api/payroll/apply" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "payslipId": "abc123"
}'

Request body

  • organizationIdreq
    string
  • payslipIdreq
    string

Response (200/201)

  • appliedreq
    number
  • statusreq
    string

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/approve#

Run approve (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the approve operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/approve

Example request

curl -X POST "https://app.guliel.com/api/payroll/approve" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "month": "string"
}'

Request body

  • organizationIdreq
    string
  • monthreq
    string
  • payslipIds
    array<string>

Response (200/201)

  • approvedreq
    integer

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/generate#

Run generate (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the generate operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/generate

Example request

curl -X POST "https://app.guliel.com/api/payroll/generate" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "month": "string"
}'

Request body

  • organizationIdreq
    string
  • monthreq
    string
  • employeeIds
    array<string>
  • runInputs
    object
    • additionalWage
      number
    • adjustments
      array<object>
      • descriptionreq
        string
      • amountreq
        number

Response (200/201)

  • generatedreq
    integer
  • errorsreq
    array<object>
    • counterpartyIdreq
      string
    • messagereq
      string

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/pay#

Run pay (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the pay operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/pay

Example request

curl -X POST "https://app.guliel.com/api/payroll/pay" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "payslipId": "abc123",
  "kind": "NET",
  "paidAt": "string"
}'

Request body

  • organizationIdreq
    string
  • payslipIdreq
    string
  • kindreq
    enum<2>
    NET · STATUTORY
  • paidAtreq
    string
  • method
    string

Response (200/201)

  • paymentIdreq
    string
  • allocatedreq
    number
  • statusreq
    string

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
GET/api/payroll/payments#

Get payments (payrolls)

scope · payroll:read

Returns the payments data for the payrolls feature.

Scope: payroll:read
Endpoint: GET /api/payroll/payments

Example request

curl "https://app.guliel.com/api/payroll/payments?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • monthreq
    string

Response (200/201)

  • monthreq
    string
  • paymentsreq
    array<object>
    • idreq
      string
    • paidAtreq
      string
    • counterpartyIdreq
      string | null
    • employeeNamereq
      string
    • amountreq
      number
    • methodreq
      string | null
    • allocatedTotalreq
      number
    • openRemainderreq
      number
    • sourcereq
      enum<3>
      ADVANCE · NET · STATUTORY
    • payslipIdsreq
      array<string>

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
DELETE/api/payroll/payslip#

Remove payslip (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Removes the payslip configuration for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: DELETE /api/payroll/payslip

Example request

curl -X DELETE "https://app.guliel.com/api/payroll/payslip?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • payslipIdreq
    string

Response (200/201)

  • deletedreq
    boolean

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/regenerate#

Run regenerate (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the regenerate operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/regenerate

Example request

curl -X POST "https://app.guliel.com/api/payroll/regenerate" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "payslipId": "abc123"
}'

Request body

  • organizationIdreq
    string
  • payslipIdreq
    string
  • runInputs
    object
    • additionalWage
      number
    • adjustments
      array<object>
      • descriptionreq
        string
      • amountreq
        number

Response (200/201)

  • documentIdreq
    string
  • totalreq
    number
  • lineCountreq
    integer

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
GET/api/payroll/summary#

Get summary (payrolls)

scope · payroll:read

Returns the summary data for the payrolls feature.

Scope: payroll:read
Endpoint: GET /api/payroll/summary

Example request

curl "https://app.guliel.com/api/payroll/summary?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • monthreq
    string

Response (200/201)

  • monthreq
    string
  • schemesreq
    array<string>
  • schemeLabelsreq
    object
  • employeesreq
    array<object>
    • counterpartyIdreq
      string
    • namereq
      string
    • payslipId
      string
    • status
      enum<3>
      DRAFT · APPROVED · PAID
    • gross
      number
    • net
      number
    • schemeAmounts
      object
    • openCreditreq
      number
    • netOutstanding
      number
    • statutoryOutstanding
      number
    • hasAppliedAdvances
      boolean
  • totalsreq
    object
    • grossreq
      number
    • netreq
      number
    • employerCostreq
      number
    • openCreditsreq
      number

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
POST/api/payroll/unapply#

Run unapply (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the unapply operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/unapply

Example request

curl -X POST "https://app.guliel.com/api/payroll/unapply" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "payslipId": "abc123"
}'

Request body

  • organizationIdreq
    string
  • payslipIdreq
    string

Response (200/201)

  • unappliedreq
    number
  • statusreq
    string
  • attachedPaymentCountreq
    integer

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
POST/api/payroll/void#

Run void (payrolls)

scope · payroll:writerole · CONTRIBUTOR+

Performs the void operation for the payrolls feature.

Scope: payroll:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/payroll/void

Example request

curl -X POST "https://app.guliel.com/api/payroll/void" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "payslipId": "abc123"
}'

Request body

  • organizationIdreq
    string
  • payslipIdreq
    string

Response (200/201)

  • statusreq
    string

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal