v1

latestOpenAPI 3.1.02026-07-263911,4691.1 MB
Schedules (legacy)

Create a schedule item

post/schedules/v1/schedule_items

Request body

descriptionstring required

Description of the schedule item

must_complete'MUST_COMPLETE_UNSPECIFIED' | 'ONE' | 'ALL' required
  • MUST_COMPLETE_UNSPECIFIED: Unspecified must complete value
  • ONE: Schedule must be completed by one assignee
  • ALL: Schedule must be completed by all assignees
can_late_submitboolean required

Can the inspections be started after the due date

recurrencestring required

RRule formatted recurrence string. <br> Example: FREQ=WEEKLY;BYDAY=MO;INTERVAL=1 represents weekly on Monday.

durationstring required

ISO8601 duration string, e.g. PT1H. How long inspection can be started after the start_date.

timezonestring

@deprecated, this field is not being used to dictate the timezone of the schedule item. The timezone of the schedule item is based on the authenticated user's profile timezone.

from_datestring date-time required

When this schedule will begin appearing

to_datestring date-time

When the schedule will end

location_idstring

The location assigned to this schedule item

idstring
modified_atstring date-time
created_atstring date-time
status'STATUS_UNSPECIFIED' | 'ACTIVE' | 'PAUSED' | 'NO_TEMPLATE' | 'NO_ASSIGNEE' | 'FINISHED' | 'SUBSCRIPTION_INACTIVE' | 'NO_SITE'
  • STATUS_UNSPECIFIED: Unspecified status value
  • ACTIVE: Default value - schedule item is still active
  • PAUSED: Schedule has been paused e.g. manually paused/org frozen
  • NO_TEMPLATE: The template used for this schedule item has been deleted/archived
  • NO_ASSIGNEE: No valid assignees exist for this schedule item anymore
  • FINISHED: The schedule item has hit its end date or count limit and is now complete
  • SUBSCRIPTION_INACTIVE: User/org subscription is inactive
  • NO_SITE: The site used for this schedule has been removed
asset_idstring

The asset assigned to this schedule item

Example request

{
  "start_time": {
    "hour": 15,
    "minute": 56
  },
  "reminders": [
    {
      "event": "START",
      "duration": "PT5M"
    }
  ],
  "assignees": [
    {
      "id": "0e7cff72-f919-4c84-aa37-e847b306423e",
      "type": "USER",
      "name": "Joe Bloggs"
    }
  ],
  "document": {
    "id": "0e7cff72-f919-4c84-aa37-e847b306423e",
    "type": "TEMPLATE",
    "name": "Joe's JSA Template"
  },
  "creator": {
    "id": "0e7cff72-f919-4c84-aa37-e847b306423e",
    "type": "USER",
    "name": "Joe Bloggs"
  }
}

Response

A successful response.

idstring

The id of the newly created schedule item