{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/safetyculture/json-schema/safetyculture-s12-scheduling-feed-v1-feed-schedule-assignees-response-schema.json",
  "title": "FeedScheduleAssigneesResponse",
  "description": "The response for `FeedScheduleAssignees` V2",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/safetyculture-data-feeds-api-openapi.yml#/components/schemas/s12.scheduling.feed.v1.FeedScheduleAssigneesResponse",
  "type": "object",
  "properties": {
    "metadata": {
      "description": "The metadata for the feed.",
      "allOf": [
        {
          "$ref": "#/$defs/s12.common.v1.FeedMetadataSimple"
        }
      ]
    },
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "$ref": "#/$defs/s12.scheduling.feed.v1.FeedScheduleAssigneeRecord"
      },
      "description": "The flat list of schedule assignee records."
    }
  },
  "$defs": {
    "s12.common.v1.FeedMetadataSimple": {
      "type": "object",
      "properties": {
        "next_page": {
          "type": "string",
          "description": "Full path to retrieve the next page of results, including the next_page_token."
        },
        "next_page_token": {
          "type": "string",
          "description": "The value you can use to retrieve additional results.\nIf a value exists, it means there are more results than listed.\nUse the value in your request body as a page_token to view more results."
        }
      },
      "description": "FeedMetadataSimple for a feed."
    },
    "s12.scheduling.feed.v1.FeedScheduleAssigneeRecord": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for this schedule-assignee relationship.\nFormat: \"scheduleitem_{schedule_id}_assignee_{assignee_id}\"\nExample: \"scheduleitem_123_assignee_456\"."
        },
        "schedule_id": {
          "type": "string",
          "description": "ID of the schedule this assignee belongs to.\nReferences a schedule from the FeedSchedules endpoint."
        },
        "assignee_id": {
          "type": "string",
          "description": "ID of the individual or entity assigned to the schedule.\nCould be a user ID, group ID (role), location ID (site), or location/group intersection."
        },
        "type": {
          "type": "string",
          "description": "Type of entity assigned to this schedule.\n• `user`: Individual user assigned\n• `role`: Group-based assignment\n• `location`: Location-based assignment (site)\n• `location_intersection`: Group assignment based on location and role intersection."
        },
        "name": {
          "type": "string",
          "description": "Display name of the assignee."
        },
        "organisation_id": {
          "type": "string",
          "description": "ID of the organization that owns the assignment."
        },
        "completion_rule": {
          "type": "string",
          "description": "Completion requirement for the occurrence. One of: `any` (at least one assignee must complete) or `all` (every assignee must complete)."
        }
      },
      "description": "A schedule assignee record returned from `FeedScheduleAssignees` V2",
      "title": "FeedScheduleAssigneeRecord"
    }
  }
}