56 lines
4.2 KiB
JSON
56 lines
4.2 KiB
JSON
{
|
|
"$id": "https://schema.owlboard.info/data-ingress/pushport-schedule.schema.json",
|
|
"$schema": "https://json-schema.org/draft-07/schema#",
|
|
"title": "PushPortSchedule",
|
|
"type": "object",
|
|
"required": ["rid", "uid", "trainId", "ssd", "toc", "locations"],
|
|
"properties": {
|
|
"rid": {"type": "string", "description": "Unique service ID"},
|
|
"uid": {"type": "string", "description": "Unique schedule ID - maps to NR CIF"},
|
|
"trainId": {"type": "string", "description": "Train Headcode"},
|
|
"ssd": {"type": "string", "format": "date", "description": "Schedule Start Date (When the service commences)"},
|
|
"toc": {"type": "string", "minLength": 2, "maxLength": 2, "description": "TOC Code"},
|
|
"isPassenger": {"type": "boolean", "description": "If service is for passengers", "default": true},
|
|
"isCharter": {"type": "boolean", "description": "If train is charter service", "default": false},
|
|
"status": {"type": "string", "enum": ["train", "bus", "ship"], "default": "train"},
|
|
"isDelayedDelivery": {"type": "boolean", "description": "If message is sent as part of Darwin service recovery"},
|
|
"cancelReason": {"type": ["string", "null"], "description": "Reason code for cancellation"},
|
|
"isDeleted": {"type": "boolean", "description": "Whether schedule should be deleted", "default": false},
|
|
"locations": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"required": ["tpl", "seq"],
|
|
"properties": {
|
|
"tpl": {"type": "string", "description": "TIPLOC of location"},
|
|
"seq": {"type": "integer", "description": "The order of the stop for sorting and handling repeated TIPLOCs"},
|
|
"wta": { "type": ["string", "null"] },
|
|
"wtd": { "type": ["string", "null"] },
|
|
"wtp": { "type": ["string", "null"] },
|
|
"pta": { "type": ["string", "null"] },
|
|
"ptd": { "type": ["string", "null"] },
|
|
"plat": { "type": ["string", "null"] },
|
|
"isCancelled": { "type": "boolean", "default": false },
|
|
"isSupressed": { "type": "boolean", "default": false, "description": "Defines whether the service should be hidden to the public"},
|
|
"activities": {
|
|
"type": "object",
|
|
"properties": {
|
|
"pickUpDropOff": {"type": "boolean", "description": "Indicates the train stops for passengers to board and alight"},
|
|
"requestStop": {"type": "boolean", "description": "Indicates if the train stops only when required"},
|
|
"pickUpOnly": {"type": "boolean", "description": "Indicated the service picks up passengers only"},
|
|
"dropOffOnly": {"type": "boolean", "description": "Indicates the service drops off passengers only"},
|
|
"tokenExchange": {"type": "boolean", "description": "Indicates if the train stops for exhanging a token/staff or similar"},
|
|
"vehiclesAttached": {"type": "boolean", "description": "Indicates if vehicles are attached at this location"},
|
|
"vehiclesDetached": {"type": "boolean", "description": "Indicates if vehicles are detached at this location"},
|
|
"trainCrewChange": {"type": "boolean", "description": "Indicates if train stops to exchange crew at this location"},
|
|
"changeLocomotive": {"type": "boolean", "description": "Indicates if train stops to exchange locomotive at this location"},
|
|
"changeEnds": {"type": "boolean", "description": "Indicates if the train reverses or driver changes ends at this location"},
|
|
"staffStop": {"type": "boolean", "description": "Indicates that the train stops for staff use only"},
|
|
"unadvertised": {"type": "boolean", "description": "Indicates that the stop is not advertised to the public"}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |