Raw schema
{
"type": "object",
"properties": {
"date_type": {
"description": "Which date the range applies to (default submitted). processed = when SafetyChain saved it; modified = last change (includes submitted when never modified); modifiedOnly = only records actually modified.",
"type": "string",
"enum": [
"submitted",
"modified",
"modifiedOnly",
"processed"
]
},
"start": {
"description": "Start of the date range, yyyy-mm-dd or yyyy-mm-dd hh:mm:ss. Not together with min_ago.",
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}:\\d{2})?$"
},
"end": {
"description": "End of the date range (default: now).",
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}:\\d{2})?$"
},
"min_ago": {
"description": "Sliding window: records from the last N minutes (1440 = a day). Not together with start.",
"type": "integer",
"minimum": 1,
"maximum": 5256000
},
"time_zone_offset": {
"description": "Hours from UTC applied to the date filters and the dates returned (default 0).",
"type": "integer",
"minimum": -12,
"maximum": 14
},
"form_name": {
"description": "Exact form name.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"form_like": {
"description": "Form name contains this text (slower than form_name).",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"location_name": {
"description": "Exact location name.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"location_like": {
"description": "Location name contains this text (slower).",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"resource_name": {
"description": "Exact resource name (customer, equipment, item or supplier).",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"resource_like": {
"description": "Resource name contains this text (slower).",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"record_number": {
"description": "One record number.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"identifier_name": {
"description": "Identifier field name, for example Lot. Use together with identifier_value.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"identifier_value": {
"description": "Identifier value that goes with identifier_name.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"is_signed": {
"description": "Only records with a sign-off or validation.",
"type": "boolean"
},
"is_verified": {
"description": "Only verified (true) records.",
"type": "boolean"
},
"record_compliance": {
"description": "Only compliant (true) or non-compliant (false) records. Records without compliance rules count as compliant.",
"type": "boolean"
},
"field_names": {
"description": "Only these fields, by full field name.",
"minItems": 1,
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 200
}
},
"field_short_names": {
"description": "Only these fields, by short name.",
"minItems": 1,
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 200
}
},
"page": {
"description": "Page number, from 1 (default 1).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100000
},
"page_rows": {
"description": "Records per page (default 20, max 100).",
"type": "integer",
"minimum": 1,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}