GuidesAPI ReferenceChangelog
Changelog
added

v1.17

In this release, we are introducing an endpoint to calculate the first payment amount and date

Calcualte first payment amount

This API endpoint enables you to calculate the pro-rata first payment based on the contractor's start date and payment cycle details.

Sample Request

{
  "data": {
    "compensation_details": {
      "payment_due_type": "REGULAR",
      "work_week_start": "Monday",
      "currency_code": "EUR",
      "scale": "monthly",
      "amount": 3000,
      "cycle_end": 31,
      "cycle_end_type": "DAY_OF_MONTH",
      "payment_due_days": 1,
      "calculation_type": "WORK_DAYS",
      "work_week_end": "Friday"
    },
    "country_code": "NL",
    "type": "ongoing_time_based",
    "start_date": "2023-03-15"
  }
}

Sample response
The total field shows the calculated pro-rate amount. first_payment_dates array shows the possible first payment dates.

{
  "data": {
    "pro_rata": {
      "rate": 3000,
      "daily_rate": 130.4348,
      "total": 1695.65,
      "calculation_type": "WORK_DAYS",
      "cycle_work_days": 13,
      "work_week_start": "Monday",
      "work_week_end": "Friday",
      "cycle_start": "2023-03-15",
      "cycle_end": "2023-03-31"
    },
    "first_payment_dates": [
      {
        "due": "2023-04-01T22:59:59.999Z"
      },
      {
        "due": "2023-05-01T22:59:59.999Z"
      },
      {
        "due": "2023-06-01T22:59:59.999Z"
      },
      {
        "due": "2023-07-01T22:59:59.999Z"
      },
      {
        "due": "2023-08-01T22:59:59.999Z"
      },
      {
        "due": "2023-09-01T22:59:59.999Z"
      },
      {
        "due": "2023-10-01T22:59:59.999Z"
      },
      {
        "due": "2023-11-01T23:59:59.999Z"
      },
      {
        "due": "2023-12-01T23:59:59.999Z"
      },
      {
        "due": "2024-01-01T23:59:59.999Z"
      }
    ]
  }
}