< All Topics
Print

Simple annual recurring event

In this example we will explore a situation where we have an annual recurring event that needs to be repeated exactly one year after its last occurence.

We can achieve this by defining a schedule with only one item. The schedule item only has four parameters, being the mandatory id and name fields, an interval field and the startAt field. The interval field has only one sub parameter, defining the recurrence pattern as “Every Year”. The startAt could be omitted, and defines the date of the first ocurrence in the series.

Besides the schedules, some general parameters are defined to indicate the period in days for which the schedule should be predicted, the current date, and an optional dateZero. Please see the request body documentation for detailed descriptions of these parameters

{
  "schedule": [
    {
      "id": "ANNUAL_INSP",
      "name": "Annual Technical Inspection",
      "interval": {
        "recurrencePattern": [
          "Every year"
        ]
      },
      "startAt": {
        "date": "2026-03-30"
      }
    }
  ],
  "period": 2190,
  "currentDate": "2025-08-30",
  "dateZero": "2024-12-31",
  "resultType": "JSON",
  "dateFormat": "Y-m-d"
}

Note that the above example does not specify a lastExecuted parameter, which may influence the resulting schedule. If we would want this schedule item to occur on the same date every year, we would include the date in the recurrence pattern like: “Every April 1st of every year”.

{
  "schedule": [
    {
      "id": "ANNUAL_INSP",
      "name": "Annual Technical Inspection",
      "interval": {
        "recurrencePattern": [
          "Every April 1st of every year"
        ]
      },
      "startAt": {
        "date": "2026-03-30"
      }
    }
  ],
  "period": 2190,
  "currentDate": "2025-08-30",
  "dateZero": "2024-12-31",
  "resultType": "JSON",
  "dateFormat": "Y-m-d"
}

Table of Contents